import java.util.*;
public class _507B {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int r = sc.nextInt();
        int x1 = Math.abs(sc.nextInt());
        int y1 = Math.abs(sc.nextInt());
        int x2 = Math.abs(sc.nextInt());
        int y2 = Math.abs(sc.nextInt());
        double dis = Math.sqrt((x2 - x1) * (x2 - x1) + (y2 - y1) * (y2 - y1));
        System.out.println((int) Math.ceil(dis / (2 * r)));
    }
}
