
import java.util.*;
import java.io.*;
public class Fff {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) throws IOException {

       BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
        String in[] = bf.readLine().split(" ");
        int r = Integer.parseInt(in[0])*2;
        int x = Integer.parseInt(in[1]);
        int y = Integer.parseInt(in[2]);
        int x1 = Integer.parseInt(in[3]);
        int y1 = Integer.parseInt(in[4]);
        int dis=(int)Math.ceil(Math.hypot(Math.abs(x-x1)*1.0, Math.abs(y-y1)));

      if(dis<r&&dis!=0){System.out.println("2");}
      else{ if(dis%r==0){System.out.println(dis/r );}
        else {System.out.println((int)Math.ceil(dis/(double)r) );}
    }}
   
   
   
    
}
