import java.util.*;
import java.io.*;

public class Main implements Runnable {
		
	public void solve() throws IOException {
                int r = nextInt();
                int diameter = 2 * r;
                
		int x1 = nextInt(); int y1 = nextInt();
                int x2 = nextInt(); int y2 = nextInt();
                
                long d = (x2 - x1) * (long)(x2 - x1) + (y2 - y1) * (long)(y2 - y1);
                
                int answer = (int)( Math.sqrt(d) / diameter) ;
                
                answer = Math.max(0, answer - 2);
                
                while(true){
                    long other = answer * (long)diameter;
                    if(other * other >= d) break;
                    answer = answer + 1;
                }
                
                out.println(answer);
	}

	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	//-----------------------------------------------------------
	public static void main(String[] args) {
		new Main().run();
	}

        public void debug(Object... arr){
            System.out.println(Arrays.deepToString(arr));
        }

        public void print1Int(int[] a){
                for(int i = 0; i < a.length; i++)
                        System.out.print(a[i] + " ");
                System.out.println();
        }
        
        public void print2Int(int[][] a){
                for(int i = 0; i < a.length; i++){
                        for(int j = 0; j < a[0].length; j++){
                                System.out.print(a[i][j] + " ");
                        }
                        System.out.println();
                }
        }
        
	public void run() {
		try {
			in = new BufferedReader(new InputStreamReader(System.in));
                        out = new PrintWriter(System.out);
			tok = null;
			solve();
			in.close();
                        out.close();
		} catch (IOException e) {
			System.exit(0);
		}
	}

	public String nextToken() throws IOException {
		while (tok == null || !tok.hasMoreTokens()) {
			tok = new StringTokenizer(in.readLine());
		}
		return tok.nextToken();
	}

	public int nextInt() throws IOException {
		return Integer.parseInt(nextToken());
	}

	public long nextLong() throws IOException {
		return Long.parseLong(nextToken());
	}

	public double nextDouble() throws IOException {
		return Double.parseDouble(nextToken());
	}
        PrintWriter out;
	BufferedReader in;
	StringTokenizer tok;
}