import java.util.*;
public class laddder{

public static void main(String[] args){
Scanner scan = new Scanner(System.in);

int r = scan.nextInt();
int x = scan.nextInt();
int y = scan.nextInt();
int x1 = scan.nextInt();
int y1 = scan.nextInt();
long diffx = Math.abs(x1-x);
long diffy= Math.abs(y1-y);
//System.out.println("diffx = "+diffx+" diffy= "+diffy);
System.out.println(diffx*diffx+diffy*diffy);
long temp = (diffx*diffx + diffy*diffy);
double val = Math.sqrt(temp);
//System.out.println("val = "+temp+ " radius = "+2*r);
long fin = (long)Math.ceil(val/(2*r));
	System.out.println(fin);

 }

}