import java.util.Scanner;

public class Test {

	static long r, x1, y1, x2, y2;

	private static long getEuclid() {
		return (long) Math.ceil(Math.sqrt((double) ((x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2))));
	}

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner sc = new Scanner(System.in);
		r = sc.nextLong(); // 2
		x1 = sc.nextLong(); // 0
		y1 = sc.nextLong(); // 0
		x2 = sc.nextLong(); // 0
		y2 = sc.nextLong(); // 4

		long distance = getEuclid();

		long res = (long) Math.ceil( distance * 1.0 / (r * 2 * 1.0));
		System.out.println(res);

	}

}
