import java.io.PrintWriter;
import java.util.HashSet;
import java.util.Scanner;
import java.util.Set;

/**
 * Created by Timur on 14.11.2016.
 */
public class _507B {
    public static void main(String args[]) {
        Scanner in = new Scanner(System.in);
        PrintWriter out = new PrintWriter(System.out);
        int r = in.nextInt();
        int x1 = in.nextInt();
        int y1 = in.nextInt();
        int x2 = in.nextInt();
        int y2 = in.nextInt();

        int difx = Math.abs(x2-x1);
        int dify = Math.abs(y2-y1);
        double d = Math.sqrt(difx*difx + dify*dify);

        int res = (int)Math.ceil(d/(2*r));
        out.print(res);

        out.close();
    }
}
