Amr loves Geometry. One day he came up with a very interesting problem.Amr has a circle of radius r and center in point (x, y). He wants the circle center to be in new position (x', y').In one step Amr can put a pin to the border of the circle in a certain point, then rotate the circle around that pin by any angle and finally remove the pin.Help Amr to achieve his goal in minimum number of steps.

Input consists of 5 space-separated integers r, x, y, x' y' (1 ≤ r ≤ 105,  - 105 ≤ x, y, x', y' ≤ 105), circle radius, coordinates of original center of the circle and coordinates of destination center of the circle respectively.

Output a single integer — minimum number of steps required to move the center of the circle to the destination point.

NoteIn the first sample test the optimal way is to put a pin at point (0, 2) and rotate the circle by 180 degrees counter-clockwise (or clockwise, no matter).

import java.io.*;
public class circle {
    public static void main(String[] args) throws IOException{
    BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
    String[] str=br.readLine().split(" ");
    Integer r=Integer.parseInt(str[0]);
    Integer x=Integer.parseInt(str[1]);
    Integer y=Integer.parseInt(str[2]);
    Integer x1=Integer.parseInt(str[3]);
    Integer y1=Integer.parseInt(str[4]);
    double k=Math.sqrt(Math.pow(Math.abs(x-x1),2)+Math.pow(Math.abs(y-y1),2));
    double p=k/(2*r);
    System.out.println((int)Math.ceil(p));

}
}

import static java.lang.Double.parseDouble;
import static java.lang.Integer.parseInt;
import static java.lang.Long.parseLong;
import static java.lang.Math.min;
import static java.lang.System.exit;

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.util.StringTokenizer;
public class Main{
     static BufferedReader in;
     static PrintWriter out;
     static StringTokenizer tok;
     static void solve() throws IOException{
          int r=Int();
          int x=Int();
          int y=Int();
          int x1=Int();
          int y1=Int();
          double dist=Math.sqrt((long)Math.abs((long)(x1-x)*(x1-x))+(long)Math.abs((long)(y1-y)*(y1-y)));
         // int t=r*2;

          out.println((int)Math.ceil(dist/(2*r)));
     }
     static int Int() throws IOException{
          return parseInt(next());
     }
     static String next() throws IOException{
          while(tok==null || !tok.hasMoreTokens()){
               tok=new StringTokenizer(in.readLine());
          }
          return tok.nextToken();
     }
     public static void main(String args[]){
          try{
               in=new BufferedReader(new InputStreamReader(System.in));
               out=new PrintWriter(new OutputStreamWriter(System.out));
               solve();
               in.close();
               out.close();
          }catch(Throwable e){
               e.printStackTrace();
               exit(1);
          }
     }
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class CircleCenter {

        public static void main(String[] args) throws IOException {
                BufferedReader scanner = new BufferedReader(new InputStreamReader(System.in));

                        StringTokenizer tokenizer = new StringTokenizer(scanner.readLine());
                        int r = Integer.parseInt(tokenizer.nextToken());
                        int x = Integer.parseInt(tokenizer.nextToken());
                        int y = Integer.parseInt(tokenizer.nextToken());
                        int xx = Integer.parseInt(tokenizer.nextToken());
                        int yy = Integer.parseInt(tokenizer.nextToken());

    double distance =  Math.sqrt(((long)xx - x) * (xx - x) + ((long)yy - y) * (yy - y));

                        System.out.println( (int)Math.ceil(distance / (2 * r)));

        }
}

import java.util.*;

public class Problem507B {

	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int r = sc.nextInt();
		int x = sc.nextInt();
		int y = sc.nextInt();
		int x1 = sc.nextInt();
		int y1 = sc.nextInt();

		double distance = Math.sqrt(Math.pow(x - x1, 2) + Math.pow(y - y1, 2));
		int minumum = (int) Math.ceil(distance / (2 * r));

		System.out.println(minumum);
	}
}

import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.BufferedReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.io.IOException;
import java.util.StringTokenizer;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 */
public class Main {
	public static void main(String[] args) {
		InputStream inputStream = System.in;
		OutputStream outputStream = System.out;
		InputReader in = new InputReader(inputStream);
		PrintWriter out = new PrintWriter(outputStream);
		TaskB solver = new TaskB();
		solver.solve(1, in, out);
		out.close();
	}
}

class TaskB {
    public void solve(int testNumber, InputReader in, PrintWriter out) {
        long r = in.nextInt();
        long x1 = in.nextInt();
        long y1 = in.nextInt();
        long x2 = in.nextInt();
        long y2 = in.nextInt();

        double dist = Math.sqrt((x1-x2) * (x1-x2) + (y1-y2)*(y1-y2));

        double sol = dist/(2.0*r);

        if (Math.abs((double)Math.round(sol) - sol) <= 0.000000000000001){
            out.print((Math.round(sol)));
        } else {
            out.println(Math.round(sol + 0.5));
        }
    }
}

class InputReader {
    public BufferedReader reader;
    public StringTokenizer tokenizer;

    public InputReader(InputStream stream){
        reader = new BufferedReader(new InputStreamReader(stream));
    }

    public String next(){
        while (tokenizer == null || !tokenizer.hasMoreTokens()){
            try {
                tokenizer = new StringTokenizer(reader.readLine());
            } catch (IOException e) {
                throw new RuntimeException("FATAL ERROR", e);
            }
        }

        return tokenizer.nextToken();
    }

    public int nextInt(){
        return Integer.valueOf(next());
    }

}

import java.util.Scanner;
public class AmrandPins {
    public static void main(String[] args)
    {
        Scanner cin = new Scanner(System.in);
        long r = cin.nextInt();
        long x1 = cin.nextInt();
        long y1 = cin.nextInt();
        long x2 = cin.nextInt();
        long y2 = cin.nextInt();

        long d = (x2 - x1)*(x2 - x1) + (y2 - y1)*(y2 - y1);

        for(int i = 0 ; i < 10000000 ; i ++)
        {
            long m = (i*2*r)*(i*2*r);
            if(m >= d )
            {
                System.out.println(i);
                break;
            }
        }

    }
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.StringTokenizer;

public class Amr_And_Pins {

	static class FastReader {
		BufferedReader br;
		StringTokenizer st;

		public FastReader() {
			br = new BufferedReader(new InputStreamReader(System.in));
		}

		String next() {
			while (st == null || !st.hasMoreElements()) {
				try {
					st = new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			}

			return st.nextToken();
		}

		int nextInt() {
			return Integer.parseInt(next());
		}

		long nextLong() {
			return Long.parseLong(next());
		}

		double nextDouble() {
			return Double.parseDouble(next());
		}

		String nextLine() {
			String str = "";

			try {
				str = br.readLine();
			} catch (IOException e) {
				e.printStackTrace();
			}

			return str;
		}
	}

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		FastReader t = new FastReader();
		PrintWriter o = new PrintWriter(System.out);
		double r = t.nextDouble(), x0 = t.nextDouble(), y0 = t.nextDouble(), x = t.nextDouble(), y = t.nextDouble();
		double dx = x0 - x, dy = y0 - y;

		if (dx == dy && dx == 0)
			o.println(0);
		else {
			double R = Math.sqrt(dx * dx + dy * dy);
			double ans = Math.ceil(R / (2 * r) - 1) + 1;

			o.println((int) ans);
		}

		o.flush();
		o.close();
	}

}

import java.util.Arrays;
import java.util.LinkedHashMap;
import java.util.Scanner;
public class scratch_16{
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
            int r= sc.nextInt();
            int x1= sc.nextInt();
            int y1= sc.nextInt();
            long ans=0;
            int x2= sc.nextInt();
            int y2= sc.nextInt();
            long h= (long)(x1-x2)*(long)(x1-x2);
            long g= (long)(y1-y2)*(long)(y1-y2);
            double d= Math.sqrt(h+g);
            double p= (d-2*r)/(2*r);

        System.out.println((int)(Math.ceil(p))+1);

    }}

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

public class first{
	static double distance(double x , double y , double x1 , double y1) {
		return Math.sqrt((x-x1)*(x-x1)+(y-y1)*(y-y1));
	}
	public static void main(String args[]) {

		Scanner s = new Scanner(System.in);

		double r,x,y,x1,y1;
		int i = 0 ;

		r = Double.parseDouble(s.next());
		x = Double.parseDouble(s.next());
		y = Double.parseDouble(s.next());
		x1 = Double.parseDouble(s.next());
		y1 = Double.parseDouble(s.next());

		while (distance(x,y,x1,y1)!=0) {
			if(Double.compare(distance(x,y,x1,y1), 2*r) == 0){
				++i;
				break;
			}if(Double.compare(distance(x,y,x1,y1), 2*r) < 0) {
				i = i+1;
				break;
			}else {
				if(Double.compare(y, y1) == 0) {
					if(Double.compare(x, x1)>0) {
						x = x - 2*r ;
					}else {
						x = x + 2*r ;
					}
				}else if(Double.compare(x, x1) == 0) {
					if(Double.compare(y, y1) > 0) {
						y = y - 2*r ;
					}else {
						y = y + 2*r ;
					}
				}else {
					double m = (y-y1)/(x-x1) ;
					double p = Math.sqrt((m*m*4*r*r)/(1+m*m)) ;
					double x2,y2;
					x2 = p/m+x;
					y2 = y+p;
					x = -p/m+x;
					y = y-p ;
					if(Double.compare(distance(x,y,x1,y1), distance(x2,y2,x1,y1)) > 0) {
						x = x2 ;
						y = y2 ;
					}

				}

			}
			i++;
		}

		System.out.println(i);
	}
}

import java.util.Scanner;

public class Main{

    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        String line = in.nextLine();
        String[] tokens = line.split("\\s+");
        double thing = (Math.sqrt((Math.pow(Integer.parseInt(tokens[1]) - Integer.parseInt(tokens[3]), 2)) +
                (Math.pow(Integer.parseInt(tokens[2]) - Integer.parseInt(tokens[4]), 2))))  / (2 * Integer.parseInt(tokens[0]));
        if(thing == 1){
            System.out.println(1);
        }
        else if(thing == 0){
            System.out.println(0);
        }
        else{
            System.out.println((int)Math.ceil(thing));
        }
    }
}

import java.util.Scanner;

public class Main_Round287Div2_B {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		double EPS = 1.0e-10;
		long r = sc.nextLong();
		long x = sc.nextLong();
		long y = sc.nextLong();
		long x1 = sc.nextLong();
		long y1 = sc.nextLong();

//		double dis = (x1 - x) * (x1 - x) + (y1 - y) * (y1 - y);
		double dis = Math.hypot(x1 - x, y1- y);
		int ret = (int)(dis / r / 2);
		if (dis - 2 * r * ret > EPS) {
			ret++;
		}

		System.out.println(ret);

		sc.close();
	}
}

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

import java.util.Scanner;

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
/**
 *
 * @author KHALED
 */
public class AmrAndPins {
    public static void main(String[] args) {
        Scanner scan=new Scanner(System.in);
        int r=scan.nextInt();
        int x1=scan.nextInt();
        int y1=scan.nextInt();
        int x2=scan.nextInt();
        int y2=scan.nextInt();
        double xd = x2 - ((double) x1);
        double yd = y2 - ((double) y1);
        double d = Math.sqrt(xd * xd + yd * yd);
        int ans = (int) (d/(r*2));
        if(d/(r*2) - ans >0){
            ans++;
        }
        System.out.println(ans);
    }
}

import java.util.*;
public class Unique {
public static void main(String[] args) {
	Scanner input=new Scanner(System.in);
	int r,x,y,a,b;
	r=input.nextInt();
	x=input.nextInt();
	y=input.nextInt();
	a=input.nextInt();
	b=input.nextInt();
	double p,l;
	p=Math.pow((a-x), 2) + Math.pow((b-y), 2);
	l=Math.sqrt(p);
	//System.out.println(l);
	int re;
	re = (int )Math.ceil(l/r/2);
	System.out.println(re);

}
}

//package Code;
import java.util.*;

import java.math.*;
import java.lang.System;
import java.nio.CharBuffer;
import static java.lang.System.*;
import java.io.InputStream;
import java.sql.Time;

public class Main
{
    public static void main(String[] args)
    {
        Double a, b, c, d, i, j, k, m, n;
        Scanner in = new Scanner(System.in);
        m = in.nextDouble();
        a = in.nextDouble();
        b = in.nextDouble();
        c = in.nextDouble();
        d = in.nextDouble();
        n = Math.sqrt(Math.pow(c - a, 2) + Math.pow(d - b, 2));
        m = m * 2.0;
        System.out.println((int)Math.ceil(n/m));
    }
}

//package codeforces;

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.Arrays;
import java.util.Comparator;
import java.util.Locale;
import java.util.StringTokenizer;

public class B {
    BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
    PrintWriter writer = new PrintWriter(System.out);
    StringTokenizer stringTokenizer;

    B() throws IOException {
//        reader = new BufferedReader(new FileReader("cycle2.in"));
//        writer = new PrintWriter(new FileWriter("cycle2.out"));
    }

    String next() throws IOException {
        while (stringTokenizer == null || !stringTokenizer.hasMoreTokens()) {
            stringTokenizer = new StringTokenizer(reader.readLine());
        }
        return stringTokenizer.nextToken();
    }

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

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

    double nextDouble() throws IOException {
        return Double.parseDouble(next());
    }

    int[][] mul(int[][] a, int[][] b) {
        int[][] result = new int[2][2];
        for (int i = 0; i < 2; i++) {
            for (int j = 0; j < 2; j++) {
                for (int k = 0; k < 2; k++) {
                    result[i][j] = sum(result[i][j], product(a[i][k], b[k][j]));
                }
            }
        }
        return result;
    }

    int[][] pow(int[][] a, int k) {
        int[][] result = {{1, 0}, {0, 1}};
        while (k > 0) {
            if (k % 2 == 1) {
                result = mul(result, a);
            }
            a = mul(a, a);
            k /= 2;
        }
        return result;
    }

    final int MOD = 1000 * 1000 * 1000 + 7;

    int sum(int a, int b) {
        a += b;
        return a >= MOD ? a - MOD : a;
    }

    int product(int a, int b) {
        return (int) (1l * a * b % MOD);
    }

    @SuppressWarnings("unchecked")
    void solve() throws IOException {
        int r = nextInt();
        int x = nextInt(), y = nextInt();
        x -= nextInt();
        y -= nextInt();
        double d = Math.sqrt(1l * x * x + 1l * y * y);
        writer.printf(Locale.US, "%.0f", Math.ceil(d / (2 * r)));
        writer.close();
    }

    public static void main(String[] args) throws IOException {
        new B().solve();
    }

}

import java.util.Scanner;
public class Pins {
	public static void main(String [] args) {
		Scanner scan = new Scanner(System.in);
		long r = scan.nextInt(), x = scan.nextInt(), y = scan.nextInt(), x1 = scan.nextInt(), y1 = scan.nextInt();
		System.out.println((int)(Math.ceil(Math.sqrt((x1-x)*(x1-x)+(y1-y)*(y1-y))/(2*r))));
	}
}

import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.IOException;
import java.lang.Math;
public class January2 {
    public static void main(String[] args) throws IOException{
         BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
        String brr[]=br.readLine().trim().split(" ");
        long r=Long.parseLong(brr[0]);
        long x1=Long.parseLong(brr[1]);
        long y1=Long.parseLong(brr[2]);
        long x2=Long.parseLong(brr[3]);
        long y2=Long.parseLong(brr[4]);
        long dist=(x1-x2)*(x1-x2)+(y1-y2)*(y1-y2);
        double p=(double) dist;
        double q=Math.sqrt(p);
        double k=(double)r;
        double n=q/(2.0*k);
        long  ans=(long) Math.ceil(n);
    System.out.println(ans);
    }
}

import java.util.*;

public class Length {
    public static int min = 0;
    public static int sg = 0;
    public static ArrayList<Integer> arr = new ArrayList<Integer>(1000);
    public static boolean possible = true;
    public static void main(String[] args){
        Scanner in = new Scanner(System.in);
        int r = in.nextInt();
        int x0 = in.nextInt();
        int y0 = in.nextInt();
        int x1 = in.nextInt();
        int y1 = in.nextInt();
        double d = Math.pow(Math.pow(x0-x1,2)+Math.pow(y0-y1,2),0.5);
        int sum = 0;
        int sg = 0;
        while(sg==0){
            if(d==0){
                sg = 1;
            }
            else if(d<2*r){
                sum++;
                sg = 1;
            }
            else {
                d -= 2 * r;
                sum++;
            }
        }
        System.out.println(sum);
    }
}

import java.util.Scanner;

public class B507 {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        double r= scanner.nextDouble();
        double x = scanner.nextDouble();
        double y = scanner.nextDouble();
        double x1 = scanner.nextDouble();
        double y1 = scanner.nextDouble();
        double dis =Math.sqrt ((x-x1)*(x-x1) + (y-y1)*(y-y1));
        if(dis == 0){
            System.out.println(0);
        }else if(dis <= 2*r){
            System.out.println(1);
        }else {
            int ans = (int)(dis / (2*r)) ;
            if (2*r * ans  < dis) {
                ans++;
            }
            System.out.println(ans);
        }
    }
}

import java.io.*;
import java.util.*;
import java.text.*;
import java.math.*;
import java.util.regex.*;

public class Solution{

	public static void main(String[] args){
		Scanner scan = new Scanner(System.in);
		long r = scan.nextInt();
		long x1 = scan.nextInt();
		long y1 = scan.nextInt();
		long x2 = scan.nextInt();
		long y2 = scan.nextInt();
		r = 2 * r;
		long target = (long)Math.sqrt((x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2));
		long count = target / r;
		count = Math.max(0, count - 1);
		while(count * count * r * r < (x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2))
			count ++;
		System.out.println(count);
		scan.close();
		return;
	}
}

//package intro_basic;

import java.util.Scanner;

public class geometry_circle {
	public static void main(String[] args)
	{
		Scanner sc=new Scanner(System.in);
		long r,x1,y1,x2,y2;
		r=sc.nextInt();
		x1=sc.nextInt();
		y1=sc.nextInt();
		x2=sc.nextInt();
		y2=sc.nextInt();

		long ans=0,mod=0;
		/*
		ans+=Math.abs((x2-x1))/(2*r);
		mod+=Math.abs((x2-x1))%(2*r);
		ans+=Math.abs((y2-y1))/(2*r);
		mod+=Math.abs((y2-y1))%(2*r);
		if(mod!=0)
		{
			ans+=1;
		}
		*/
		long y=Math.abs(y2-y1);
		long x=Math.abs(x2-x1);
		double dist=Math.sqrt(y*y+x*x);
		ans=(long)dist/(2*r);
		double dist2=(long)dist;
		if(dist!=dist2 || dist2%(2*r)!=0)
		{ans++;}
		System.out.println(ans);
	}
}

import java.io.InputStreamReader;
import java.io.IOException;
import java.io.BufferedReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.util.StringTokenizer;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 */
public class Main {
	public static void main(String[] args) {
		InputStream inputStream = System.in;
		OutputStream outputStream = System.out;
		InputReader in = new InputReader(inputStream);
		PrintWriter out = new PrintWriter(outputStream);
		TaskB solver = new TaskB();
		solver.solve(1, in, out);
		out.close();
	}
}

class TaskB {
    public void solve(int testNumber, InputReader in, PrintWriter out) {
        long r = in.nextInt();
        long x = in.nextInt();
        long y = in.nextInt();
        long x1 = in.nextInt();
        long y1 = in.nextInt();

        long od = (x1 - x) * (x1 - x) + (y1 - y) * (y1 - y);

        long b = 2L * r;

        double odl = Math.sqrt((double) od);

        long X = (long) (odl / b);

        if (b * X < odl) {
            X++;
        }

        if (x1 == x && y1 == y) {
            out.println(0);
        } else {
            out.println(X);
        }
    }
}

class InputReader {
    public BufferedReader reader;
    public StringTokenizer tokenizer;

    public InputReader(InputStream stream) {
        reader = new BufferedReader(new InputStreamReader(stream), 32768);
        tokenizer = null;
    }

    public String next() {
        while (tokenizer == null || !tokenizer.hasMoreTokens()) {
            try {
                tokenizer = new StringTokenizer(reader.readLine());
            } catch (IOException e) {
                throw new RuntimeException(e);
            }
        }
        return tokenizer.nextToken();
    }

    public int nextInt() {
        return Integer.parseInt(next());
    }
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class CircleCenter {

        public static double getDistance(long x, long y, long xx, long yy) {
                return Math.sqrt((xx - x) * (xx - x) + (yy - y) * (yy - y));
        }

        public static void main(String[] args) throws IOException {
                BufferedReader scanner = new BufferedReader(new InputStreamReader(System.in));

                        StringTokenizer tokenizer = new StringTokenizer(scanner.readLine());
                        int r = Integer.parseInt(tokenizer.nextToken());
                        int x = Integer.parseInt(tokenizer.nextToken());
                        int y = Integer.parseInt(tokenizer.nextToken());
                        int xx = Integer.parseInt(tokenizer.nextToken());
                        int yy = Integer.parseInt(tokenizer.nextToken());

    double distance =  getDistance(x, y, xx, yy);

                        System.out.println( (int)Math.ceil(distance / (2 * r)));

        }
}

import java.util.*;
import java.io.*;
public class Main
{
public static void main(String args[]) throws java.lang.Exception
     {
        Scanner sc=new Scanner(System.in);
        PrintWriter out=new PrintWriter(System.out);
        double r=sc.nextInt();
        double x=sc.nextInt();
        double y=sc.nextInt();
        double xx=sc.nextInt();
        double yy=sc.nextInt();
        double dis=Math.sqrt((xx-x)*(xx-x)+(yy-y)*(yy-y));
        out.println((int)Math.ceil(dis/(2*r)));
        out.flush();
     }
}

import java.util.*;
import java.io.*;
public class Solution {
	static class FastReader
    {
        BufferedReader br;
        StringTokenizer st;

        public FastReader()
        {
            br = new BufferedReader(new
                     InputStreamReader(System.in));
        }

        String next()
        {
            while (st == null || !st.hasMoreElements())
            {
                try
                {
                    st = new StringTokenizer(br.readLine());
                }
                catch (IOException  e)
                {
                    e.printStackTrace();
                }
            }
            return st.nextToken();
        }

        int nextInt()
        {
            return Integer.parseInt(next());
        }

        long nextLong()
        {
            return Long.parseLong(next());
        }

        double nextDouble()
        {
            return Double.parseDouble(next());
        }

        String nextLine()
        {
            String str = "";
            try
            {
                str = br.readLine();
            }
            catch (IOException e)
            {
                e.printStackTrace();
            }
            return str;
        }
    }
  public static void main(String [] args) {
	FastReader ip=new FastReader();
	int r=ip.nextInt();
	long x1=ip.nextLong();
	long y1=ip.nextLong();
	long x2=ip.nextLong();
	long y2=ip.nextLong();
	long a=(x2-x1)*(x2-x1);

	long b=(y2-y1)*(y2-y1);

	double v=Math.sqrt(a+b);
    int ans=(int)Math.ceil(v/(2*r));
    System.out.println(ans);

  }
}

import java.util.Scanner;

public class Main
{
    public static void main(String[] args)
    {
        Scanner scan = new Scanner(System.in);
        int r , x1 , y1 , x2 , y2 , ans = 0;
        double dist , d;

        r = scan.nextInt();
        x1 = scan.nextInt();
        y1 = scan.nextInt();
        x2 = scan.nextInt();
        y2 = scan.nextInt();

        // 进行处理
        dist = getDist(x1 , y1 , x2 , y2);
        d = 2 * r;

//        System.out.println(dist);

        // 如果距离为0
        if (dist == 0)
            System.out.println(0);
        // 如果距离小于等于直径
        else if (dist <= d)
            System.out.println(1);
        // 如果距离大于直径
        else
        {
            while (dist > d)
            {
                dist -= d;
                ans ++;
            }
            // 如果有多余的距离
            if (dist <= d)
                ans ++;
            System.out.println(ans);
        }
    }

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

}

import java.util.Scanner;

public class spiders
{

	public static void main(String[] args) throws Exception
	{
		Scanner s = new Scanner(System.in);
		int r = s.nextInt();
		int x1 = s.nextInt();
		int y1 = s.nextInt();
		int x2 = s.nextInt();
		int y2 = s.nextInt();
		System.out.println((int)Math.ceil(Math.sqrt(Math.pow(x1-x2,2)+Math.pow(y1-y2, 2))/(2*r)));
	}

}

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

import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int r = sc.nextInt() , x = sc.nextInt() , y = sc.nextInt();
        int x1 = sc.nextInt() , y1 = sc.nextInt();
        double count = Math.sqrt(Math.pow(x1-x,2)+Math.pow(y1-y,2));
        count/=(2*r);
        System.out.println((long)Math.ceil(count));
    }
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
public class codeforces{

    public static int solve(int r,int x1,int y1,int x2,int y2){
       return (int)Math.ceil((Math.sqrt(Math.pow((x2-x1),2)+Math.pow((y2-y1),2)))/(2*r));
    }

    public static void main(String[] args) throws IOException {
        InputStreamReader isr=new InputStreamReader(System.in);
        BufferedReader br=new BufferedReader(isr);
        // StringBuilder str=new StringBuilder();
        PrintWriter out=new PrintWriter(System.out);
        // int n=Integer.parseInt(br.readLine());
        String[] lol=br.readLine().split(" ");
        int r=Integer.parseInt(lol[0]);
        int x1=Integer.parseInt(lol[1]);
        int y1=Integer.parseInt(lol[2]);
        int x2=Integer.parseInt(lol[3]);
        int y2=Integer.parseInt(lol[4]);
        out.println(solve(r,x1,y1,x2,y2));
        out.close();
    }
}

import static java.lang.System.in;

import java.io.IOException;

public class B287 {

    static byte[] buffer = new byte[8192];
    static int offset = 0;
    static int bufferSize = 0;
    public static void main(String args[])throws IOException
    {
        long r = readLong();
         long x =readLong();
        long y =readLong();
        long a =readLong();
        long b = readLong();
        double dist = Math.sqrt((x-a)*(x-a) + (y-b)*(y-b));
        double di = (int)(dist);
        long r1 = (int)di;
        long ans  = r1/(2*r);
        //System.out.println(dist +" " +di);
        if (x==a && y==b)
        {
            System.out.println(0);
            return;
        }
        if (r1%(2*r)==0 && Double.compare(dist, di)!=0)
            ans++;
        else if (r1%(2*r)!=0 && Double.compare(dist, di)!=0)
            ans++;
        else if (r1%(2*r)!=0 && Double.compare(dist, di)==0)
            ans++;
        System.out.println(ans);

    }

    static int readInt() throws IOException{
        int number = 0;
        int s =1;
        if(offset==bufferSize){
            offset = 0;
            bufferSize = in.read(buffer);
        }
        for(;buffer[offset]<0x30 || buffer[offset]=='-'; ++offset)
        {
            if (buffer[offset]=='-')
                s=-1;
            if(offset==bufferSize-1 ){
                offset=-1;
                bufferSize = in.read(buffer);
            }
        }
        for(;offset<bufferSize && buffer[offset]>0x2f;++offset){
            number = number*0x0a+buffer[offset]-0x30;
            if(offset==bufferSize-1){
                offset = -1;
                bufferSize = in.read(buffer);
            }
        }
        ++offset;
        return number*s;
    }

    static long readLong() throws IOException{
        long number = 0;
        long s=1;
        if(offset==bufferSize){
            offset = 0;
            bufferSize = in.read(buffer);
        }
        for(;buffer[offset]<0x30; ++offset)
        {
            if (buffer[offset]=='-')
                s=-1;
            if(offset==bufferSize-1){
                offset=-1;
                bufferSize = in.read(buffer);
            }
        }
        for(;offset<bufferSize && buffer[offset]>0x2f;++offset){
            number = number*0x0a+buffer[offset]-0x30;
            if(offset==bufferSize-1){
                offset = -1;
                bufferSize = in.read(buffer);
            }
        }
        ++offset;
        return number*s;
    }

}

import java.util.*;

public class Main{
    public static void main (String args[]){

            Scanner in = new Scanner(System.in);
            int r = in.nextInt();
            long x = in.nextLong();
            long y = in.nextLong();
            long x1 = in.nextLong();
            long y1 = in.nextLong();

            double d = Math.sqrt(((x1-x)*(x1-x))+((y1-y)*(y1-y)));
            int ans = (int)(d/(r*2));
            if(d%(r*2)>0){
                ans++;
            }
            System.out.println(ans);
    }

}

import java.util.*;
import java.lang.*;
public class solution {
    public static void main(String[] args){
        Scanner scan=new Scanner(System.in);
        int r,x,y,x1,y1,res;
        r=scan.nextInt();
        x=scan.nextInt();
        y=scan.nextInt();
        x1=scan.nextInt();
        y1=scan.nextInt();
        double dist=Math.sqrt(Math.pow((x1-x), 2)+Math.pow((y1-y),2));
        if(dist%r==0){
            int dev=(int)dist/r;
            if(dev%2==0)res=dev/2;
            else res=(dev-1)/2+1;
        }
        else{
            int dev=(int)dist/r;
            if(dev%2==0)res=dev/2+1;
            else res=(dev-1)/2+1;
        }
        System.out.println(res);
    }
}

import java.util.*;

public class contest1 {

	public static void main(String[] args) {
    	Scanner s = new Scanner(System.in);
    	long r = s.nextInt();
    	long x = s.nextInt();
    	long y = s.nextInt();
    	long x1 = s.nextInt();
    	long y1 = s.nextInt();
    	System.out.println((int)Math.ceil(Math.sqrt((x1-x)*(x1-x)+(y1-y)*(y1-y))/(2*r)));

    }
}

import java.io.BufferedReader;
import java.io.FileReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.math.BigInteger;
import java.util.StringTokenizer;

public class ok {

	public static void main(String[] args) {
		InputReader in = new InputReader(System.in);
		long r;
		int x, y, xx, yy;
	    r = in.nextInt();
	    x = in.nextInt();
	    y = in.nextInt();
	    xx = in.nextInt();
	    yy = in.nextInt();
	    r*=2;
	    long dist = (x - xx) * 1L * (x - xx) + (y - yy) * 1L * (y - yy);
	    r *= r;
	    int L = 0, R = 1000000;
	    while(R > L)
	    {
	        int mid = L + (R - L) / 2;
	        BigInteger temp = BigInteger.valueOf(mid);
	        temp = temp.multiply(BigInteger.valueOf(mid));
	        temp = temp.multiply(BigInteger.valueOf(r));
	        int test = temp.compareTo(BigInteger.valueOf(dist));
	        if(test == 0 || test == 1)
	            R = mid;
	        else L = mid + 1;
	    }
	    System.out.println(R);
	}

	static class InputReader {
        private BufferedReader reader;
        private StringTokenizer tokenizer;

        public InputReader(InputStream stream) {
            reader = new BufferedReader(new InputStreamReader(stream));
            tokenizer = null;
        }

        public InputReader(FileReader stream) {
            reader = new BufferedReader(stream);
            tokenizer = null;
        }

        public String nextLine() {
            try {
                return reader.readLine();
            } catch (IOException e) {
                e.printStackTrace();
                return null;
            }
        }

        public String next() {
            while (tokenizer == null || !tokenizer.hasMoreTokens()) {
                try {
                    tokenizer = new StringTokenizer(reader.readLine());
                } catch (IOException e) {
                    throw new RuntimeException(e);
                }
            }
            return tokenizer.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }

        public long nextLong() {
            return Long.parseLong(next());
        }
    }
}

import java.util.*;
import java.io.*;
import java.lang.*;
import java.math.*;

import static java.lang.Math.*;

public class Solution implements Runnable {

    void solve() throws Exception {
    	int r = sc.nextInt();
    	int x = sc.nextInt();
    	int y = sc.nextInt();
    	int xx = sc.nextInt();
    	int yy = sc.nextInt();
    	double di = sqrt((xx - x) * 1.0 * (xx - x) + (yy - y) * 1.0 * (yy - y));
    	if (di == 0) {
    		out.println(0);
    		return;
    	}
    	if (di <= 2 * r) {
    		out.println(1);
    		return;
    	}
    	di -= 2 * r;
    	int ans = 2 + (int)(di / (2.0 * r) - (1e-9));
    	out.println(ans);
    }

    BufferedReader in;
    PrintWriter out;
    FastScanner sc;

    final String INPUT_FILE = "stdin";
    final String OUTPUT_FILE = "stdout";

    static Throwable throwable;

    public static void main(String[] args) throws Throwable {
        Thread thread = new Thread(null, new Solution(), "", (1 << 26));
        thread.start();
        thread.join();
        thread.run();
        if (throwable != null)
            throw throwable;
    }

    public void run() {
        try {
            if (INPUT_FILE.equals("stdin"))
                in = new BufferedReader(new InputStreamReader(System.in));
            else
                in = new BufferedReader(new FileReader(INPUT_FILE));
            if (OUTPUT_FILE.equals("stdout"))
                out = new PrintWriter(System.out);
            else
                out = new PrintWriter(new FileWriter(OUTPUT_FILE));
            sc = new FastScanner(in);
            solve();
        } catch (Exception e) {
            throwable = e;
        } finally {
            out.close();
        }
    }
}

class FastScanner {
    BufferedReader reader;
    StringTokenizer strTok;

    FastScanner(BufferedReader reader) {
        this.reader = reader;
    }

    public String nextToken() throws Exception {
        while (strTok == null || !strTok.hasMoreTokens())
            strTok = new StringTokenizer(reader.readLine());
        return strTok.nextToken();
    }

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

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

    public double nextDouble() throws Exception {
        return Double.parseDouble(nextToken());
    }
}

import java.util.*;

public final class TestClass {
    public static void main(String args[] ) throws Exception {
        Scanner in=new Scanner(System.in);
       long r=in.nextLong();
       long x=in.nextLong();
       long y=in.nextLong();
       long x1=in.nextLong();
       long y1=in.nextLong();
       double res=Math.sqrt((x1-x)*(x1-x)+(y1-y)*(y1-y));
      long ans=(long)Math.ceil(res/(2*r));
      System.out.println(ans);
    }
}

import java.util.*;
import java.io.*;
import java.math.BigInteger;
import java.text.*;
public class Main {
    static long mod = (long)1e9 + 7;
    static long mod1 = 998244353;
    static boolean fileIO = false;
    static FastScanner f;
    static PrintWriter pw = new PrintWriter(System.out);
    static Scanner S = new Scanner(System.in);
    public static void solve() {
        long r = f.nextLong(); long x = f.nextLong(); long y = f.nextLong(); long xx = f.nextLong(); long yy = f.nextLong();
        double d = Math.sqrt(((x - xx) * (x - xx)) + ((y - yy) * (y - yy)));
        long ans = (long)Math.ceil(d / (r << 1));
        pn(ans);
    }
    public static void main(String[] args)throws IOException {
        init();
        int t = 1;
        while(t --> 0) {
            solve();
        }
        pw.flush();
        pw.close();
    }

/******************************END OF MAIN PROGRAM*******************************************/
    public static void init()throws IOException{if(fileIO){f=new FastScanner("");}else{f=new FastScanner(System.in);}}
    public static class FastScanner {
        BufferedReader br;StringTokenizer st;
        FastScanner(InputStream stream){try{br=new BufferedReader(new InputStreamReader(stream));}catch(Exception e){e.printStackTrace();}}
        FastScanner(String str){try{br=new BufferedReader(new FileReader("!a.txt"));}catch(Exception e){e.printStackTrace();}}
        String next(){while(st==null||!st.hasMoreTokens()){try{st=new StringTokenizer(br.readLine());}catch(IOException e){e.printStackTrace();}}return st.nextToken();}
        String nextLine()throws IOException{return br.readLine();}int nextInt(){return Integer.parseInt(next());}long nextLong(){return Long.parseLong(next());}double nextDouble(){return Double.parseDouble(next());}
    }
    public static void pn(Object o){pw.println(o);}
    public static void p(Object o){pw.print(o);}
    public static void pni(Object o){pw.println(o);pw.flush();}
    static class Point implements Comparator<Point>{int x;int y;Point(int x,int y){this.x=x;this.y=y;}Point(){}public int compare(Point a, Point b){if(a.x==b.x)return a.y-b.y;return a.x-b.x;}}
    static int gcd(int a,int b){if(b==0)return a;else{return gcd(b,a%b);}}
    static long gcd(long a,long b){if(b==0)return a;else{return gcd(b,a%b);}}
    static long pow(long a,long b){long res=1;while(b>0){if((b&1)==1)res=res*a;b>>=1;a=a*a;}return res;}
    static long mpow(long a,long b){long res=1;while(b>0){if((b&1)==1)res=((res%mod)*(a%mod))%mod;b>>=1;a=((a%mod)*(a%mod))%mod;}return res;}
    static boolean isPrime(long n){if(n<=1)return false;if(n<=3)return true;if(n%2==0||n%3==0)return false;for(long i=5;i*i<=n;i=i+6)if(n%i==0||n%(i+2)==0)return false;return true;}
    static HashSet<Long> factors(long n){HashSet<Long> hs=new HashSet<Long>();for(long i=1;i<=(long)Math.sqrt(n);i++){if(n%i==0){hs.add(i);hs.add(n/i);}}return hs;}
    static int[] inpint(int n){int arr[]=new int[n];for(int i=0;i<n;i++){arr[i]=f.nextInt();}return arr;}
    static long[] inplong(int n){long arr[] = new long[n];for(int i=0;i<n;i++){arr[i]=f.nextLong();}return arr;}
    static HashSet<Integer> hsi(){return new HashSet<Integer>();}static HashSet<Long> hsl(){return new HashSet<Long>();}
    static ArrayList<Integer> ali(){return new ArrayList<Integer>();}static ArrayList<Long> all(){return new ArrayList<Long>();}
    static HashMap<Integer,Integer> hii(){return new HashMap<Integer,Integer>();}
    static HashMap<Integer,ArrayList<Integer>> g(){return new HashMap<Integer,ArrayList<Integer>>();}
    static boolean ise(int x){return ((x&1)==0);}static boolean ise(long x){return ((x&1)==0);}
    static void sort(int[] a){ArrayList<Integer> l=new ArrayList<>();for(int i:a)l.add(i);Collections.sort(l);for(int i=0;i<a.length;++i)a[i]=l.get(i);}
    static void sort(long[] a){ArrayList<Long> l=new ArrayList<>();for(long i:a)l.add(i);Collections.sort(l);for(int i=0;i<a.length;++i)a[i]=l.get(i);}
}

import java.util.*;
public class B507 {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
         Scanner s = new Scanner(System.in);
        int r = s.nextInt();
        int x = s.nextInt();
        int y = s.nextInt();
        int x1 = s.nextInt();
        int y1 = s.nextInt();
        double r1 = Math.sqrt(Math.pow(x-x1,2)+Math.pow(y-y1,2));
        r1/=(2*r);
        int res = (int)r1;
        if(res<r1){
            res++;
        }
        System.out.println(res);
	}
}

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

/**
 * @author pvasilyev
 * @since 23 Jan 2015
 */
public class B {

    public static void main(String[] args) {
        final Scanner reader = new Scanner(System.in);
        final PrintWriter writer = new PrintWriter(System.out);

        solve(reader, writer);

        reader.close();
        writer.close();
    }

    private static void solve(final Scanner reader, final PrintWriter writer) {
        final int radius = reader.nextInt();
        final long x1 = reader.nextInt();
        final long y1 = reader.nextInt();
        final long x2 = reader.nextInt();
        final long y2 = reader.nextInt();

        double distBetweenCenters = Math.sqrt((x2 - x1) * (x2 - x1) + (y2 - y1) * (y2 - y1));

        int numberOfMoves = ((int) Math.ceil(distBetweenCenters / 2 / radius));
        writer.println(numberOfMoves);
    }

}

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

public class apin {

	int rr;
	int xx;
	int yy;
	int xx1;
	int yy1;
	int nn;

	public apin() throws Exception
	{
		BufferedReader f = new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st = new StringTokenizer(f.readLine());
		rr = Integer.parseInt(st.nextToken());
		xx = Integer.parseInt(st.nextToken());
		yy = Integer.parseInt(st.nextToken());
		xx1 = Integer.parseInt(st.nextToken());
		yy1 = Integer.parseInt(st.nextToken());

	    f.close();
	}

	public void compute()
	{
		double deltax = (double)(xx1 - xx);
		double deltay = (double)(yy1 - yy);
		int dist = (int)(Math.ceil(Math.sqrt(deltax * deltax + deltay * deltay)));
		nn = dist / (2 * rr);
		int re = dist - nn * 2 * rr;
		if(re > 0)
			++nn;
	}

	public void results()
	{
	    System.out.println("" + nn);
	}

  public static void main (String [] args) throws Exception {
	  apin aa = new apin();
    aa.compute();
    aa.results();
  }
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class CircleCenter {
    public static int numberOfSteps(int r, int x, int y, int xx, int yy) {
        double distance = getDistance(x, y, xx, yy);
        return (int)Math.ceil(distance / (2 * r));
    }

    public static double getDistance(long x, long y, long xx, long yy) {
        return Math.sqrt((xx - x) * (xx - x) + (yy - y) * (yy - y));
    }

    public static void main(String[] args) throws IOException {
        BufferedReader scanner = new BufferedReader(new InputStreamReader(System.in));
            StringTokenizer tokenizer = new StringTokenizer(scanner.readLine());
            int r = Integer.parseInt(tokenizer.nextToken());
            int x = Integer.parseInt(tokenizer.nextToken());
            int y = Integer.parseInt(tokenizer.nextToken());
            int xx = Integer.parseInt(tokenizer.nextToken());
            int yy = Integer.parseInt(tokenizer.nextToken());

            System.out.println(numberOfSteps(r, x, y, xx, yy));
    }
}

import java.util.*;
public class Main {

    public static void main(String[] args) {
        Scanner input = new Scanner(System.in);
         double r = input.nextDouble();
        double x = input.nextDouble();
          double y = input.nextDouble();
            double x1 = input.nextDouble();
              double y1 = input.nextDouble();
              double d = Math.sqrt((x1-x)*(x1-x)+(y1-y)*(y1-y));
              double step =  Math.ceil(d/r/2);
              int a = (int)step;
              System.out.println(a);
    } }

import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        int r=s.nextInt(), x1=s.nextInt(), y1=s.nextInt(), x2=s.nextInt(), y2=s.nextInt();
        int time=0;
        s.close();
        double distance=Math.sqrt(Math.pow(Math.abs(x1-x2),2)+Math.pow(Math.abs(y1-y2),2));
        //System.out.println(distance);
        double c1 = distance/r;
        //System.out.println(Math.floor(c1));
        //if(Math.floor(c1)==c1){
            while(distance>0){
                distance=distance-r*2;
                time++;
            }
        //}
        System.out.println(time);
    }
}

import java.util.*;

public class B {

    public static void main(String[] args) {
    	Scanner s = new Scanner(System.in);
    	int r = s.nextInt();
    	int x = s.nextInt();
    	int y = s.nextInt();
    	int xx = s.nextInt();
    	int yy = s.nextInt();
    	System.out.println((int)Math.ceil(Math.sqrt(Math.pow(x-xx,2)+Math.pow(y-yy,2))/(2*r)));
    }
}

import java.util.*;

public class B507 {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		double r = scan.nextDouble(), x = scan.nextDouble(), y = scan.nextDouble(), x1 = scan.nextDouble(),
				y1 = scan.nextDouble();
		double d = Math.sqrt((x1 - x) * (x1 - x) + (y1 - y) * (y1 - y));
		double res = Math.ceil(d / (2 * r));

		System.out.println((int) res);

	}
}

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

public class Solution {
    public static void main(String[] args) throws Exception{
        Scanner sc = new Scanner(System.in);
        PrintWriter pw = new PrintWriter(System.out);
        int r = sc.nextInt(), x = sc.nextInt(), y = sc.nextInt(), x1 = sc.nextInt(), y1 = sc.nextInt();
        if (x < 0) {
            x1 -= x;
            x = 0;
        }
        if (x1 < 0) {
            x -= x1;
            x1 = 0;
        }
        if (y < 0) {
            y1 -= y;
            y = 0;
        }
        if (y1 < 0) {
            y -= y1;
            y1 = 0;
        }
        double rasst = Math.sqrt(Math.pow(x-x1, 2) + Math.pow(y-y1, 2));
        int k = 0;
        if (x == x1 && y == y1) {
            rasst = 0;
        } else if (rasst<=2*r) {
            k = 1;
            rasst = 0;
        } else {
            while (rasst > 0) {
                rasst = Math.max(0, rasst-2*r);
                k++;
            }
        }
        pw.println(k);
        pw.close();
    }
}

import java.util.*;
import java.io.*;
import java.lang.*;
public class Main {
    public static void main(String args[] ) {
        Scanner scan = new Scanner(System.in);
        int r = scan.nextInt();
        int x1 = scan.nextInt();
        int y1 = scan.nextInt();
        int x2 = scan.nextInt();
        int y2 = scan.nextInt();
        double d =Math.hypot((x2-x1), (y2-y1));

        double f = Math.ceil(d);
        int a = (int)Math.ceil(f/(r+r));
        System.out.println(a);

    }
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class ProblemB {

    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        StringTokenizer st = new StringTokenizer(br.readLine());
        int r = Integer.parseInt(st.nextToken());
        int x = Integer.parseInt(st.nextToken());
        int y = Integer.parseInt(st.nextToken());
        int newx = Integer.parseInt(st.nextToken());
        int newy = Integer.parseInt(st.nextToken());

        long distances =(((long)newx - x)*(newx - x)) + (((long)newy - y)*(newy - y));
        long distance = (long) Math.ceil(Math.sqrt(distances));
        long rotations = distance / (2 * r);
        if(distance % (2 * r) != 0){
            rotations++;
        }
        System.out.println(rotations);
    }
}

import java.util.Scanner;
import java.util.StringTokenizer;

public class alphatest {

	public static void main(String[] args){

	Scanner sc=new Scanner(System.in);

int r=sc.nextInt();
int x0=sc.nextInt();
int y0=sc.nextInt();

int x1=sc.nextInt();
int y1=sc.nextInt();

double dist=Math.sqrt(Math.pow((x1-x0), 2)+Math.pow((y1-y0), 2));

System.out.println((int)Math.ceil(dist/(2*r)));

}
}

import java.util.*;
public class KnightTemplar {
public static void main(String [] args){
	Scanner in=new Scanner(System.in);
	int r=in.nextInt();
	double x=in.nextInt();
	double y=in.nextInt();
	double x1=in.nextInt();
	double y1=in.nextInt();

	double dist=(x1-x)*(x1-x) + (y1-y)*(y1-y);
	dist=Math.sqrt(dist);
	dist=Math.ceil(dist/(2*r));
	System.out.print((int)dist);
}
}

import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.io.BufferedWriter;
import java.io.Writer;
import java.io.OutputStreamWriter;
import java.util.InputMismatchException;
import java.io.IOException;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author fakhoury
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        OutputWriter out = new OutputWriter(outputStream);
        BAmrAndPins solver = new BAmrAndPins();
        solver.solve(1, in, out);
        out.close();
    }

    static class BAmrAndPins {
        public void solve(int testNumber, InputReader in, OutputWriter out) {
            long r = in.nextLong();

            long x1 = in.nextLong();
            long y1 = in.nextLong();
            long x2 = in.nextLong();
            long y2 = in.nextLong();

            long dist = (x2 - x1) * (x2 - x1) + (y2 - y1) * (y2 - y1);
            out.print((int) Math.ceil(Math.sqrt(dist) / (2 * r)));
        }

    }

    static class OutputWriter {
        private final PrintWriter writer;

        public OutputWriter(OutputStream outputStream) {
            writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));
        }

        public OutputWriter(Writer writer) {
            this.writer = new PrintWriter(writer);
        }

        public void close() {
            writer.close();
        }

        public void print(int i) {
            writer.print(i);
        }

    }

    static class InputReader {
        private InputStream stream;
        private byte[] buf = new byte[1024];
        private int curChar;
        private int numChars;
        private InputReader.SpaceCharFilter filter;

        public InputReader(InputStream stream) {
            this.stream = stream;
        }

        public int read() {
            if (numChars == -1) {
                throw new InputMismatchException();
            }
            if (curChar >= numChars) {
                curChar = 0;
                try {
                    numChars = stream.read(buf);
                } catch (IOException e) {
                    throw new InputMismatchException();
                }
                if (numChars <= 0) {
                    return -1;
                }
            }
            return buf[curChar++];
        }

        public long nextLong() {
            int c = read();
            while (isSpaceChar(c)) {
                c = read();
            }
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            long res = 0;
            do {
                if (c < '0' || c > '9') {
                    throw new InputMismatchException();
                }
                res *= 10;
                res += c - '0';
                c = read();
            } while (!isSpaceChar(c));
            return res * sgn;
        }

        public boolean isSpaceChar(int c) {
            if (filter != null) {
                return filter.isSpaceChar(c);
            }
            return isWhitespace(c);
        }

        public static boolean isWhitespace(int c) {
            return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }

        public interface SpaceCharFilter {
            public boolean isSpaceChar(int ch);

        }

    }
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class C507B {
	private StringTokenizer st;
	private BufferedReader bf;

	public C507B() {
		try {
			bf = new BufferedReader(new InputStreamReader(System.in));
			st = new StringTokenizer(bf.readLine());

			int r = nextInt();
			int x1 = nextInt();
			int y1 = nextInt();
			int x2 = nextInt();
			int y2 = nextInt();

			long x = Math.abs(x2-x1);
			long y = Math.abs(y2-y1);
			double sq = Math.sqrt(x*x+y*y);
//			double sq = Math.sqrt((x2-x1)*(x2-x1)+(y2-y1)*(y2-y1));
			System.out.println((long)(Math.ceil(sq / (r*2.0))));
//			double d = Math.sqrt((x2-x1)*(x2-x1)+(y2-y1)*(y2-y1));
//			int dd =r*2;
//			int cut = 0;
//			double ans = 0.0;

//			while (d > ans) {
//				cut++;
////				ans = dd * cut;
//				ans += dd;
//			}
//			System.out.println(cut);

		} catch (Exception e) {
			e.printStackTrace();
		}
	}

	private int nextInt() throws IOException {
		return Integer.parseInt(next());
	}

	private String next() throws IOException {
		if (st == null || !st.hasMoreTokens())
			st = new StringTokenizer(bf.readLine());
		return st.nextToken();
	}
	public static void main(String[] args) {
		// TODO Auto-generated method stub
		C507B c = new C507B();
	}
}

import java.util.*;

public class Length {
    public static int min = 0;
    public static int sg = 0;
    public static ArrayList<Integer> arr = new ArrayList<Integer>(1000);
    public static boolean possible = true;
    public static void main(String[] args){
        Scanner in = new Scanner(System.in);
        int r = in.nextInt();
        int x0 = in.nextInt();
        int y0 = in.nextInt();
        int x1 = in.nextInt();
        int y1 = in.nextInt();
        double d = Math.pow(Math.pow(x0-x1,2)+Math.pow(y0-y1,2),0.5);
        int sum = 0;
        int sg = 0;
        while(sg==0){
            if(d==0){
                sg = 1;
            }
            else if(d<2*r){
                sum++;
                sg = 1;
            }
            else {
                d -= 2 * r;
                sum++;
            }
        }
        System.out.println(sum);
    }
}

import java.io.*;
public class circle {
    public static void main(String[] args) throws IOException{
    BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
    String[] str=br.readLine().split(" ");
    Integer r=Integer.parseInt(str[0]);
    Integer x=Integer.parseInt(str[1]);
    Integer y=Integer.parseInt(str[2]);
    Integer x1=Integer.parseInt(str[3]);
    Integer y1=Integer.parseInt(str[4]);
    double k=Math.sqrt(Math.pow(Math.abs(x-x1),2)+Math.pow(Math.abs(y-y1),2));
    double p=k/(2*r);
    System.out.println((int)Math.ceil(p));

}
}

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);

	}

}

import java.util.*;

public class armspins
{
	public static void main(String args[])
	{
		Scanner sc = new Scanner(System.in);
		long r = sc.nextLong(), x1 = sc.nextLong(), y1 = sc.nextLong(), x2 = sc.nextLong(), y2 = sc.nextLong();
        double a = Math.sqrt(((x2-x1)*(x2-x1)+(y2-y1)*(y2-y1)))/(2*r);
		System.out.print((int)Math.ceil(a));
	}
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

/**
 *

 0  0
------
 0  2
 0 -2
 2  0
-2  0
------

 1  1
------
 1  2
 1  0
 0  1
 1  0
 * */
public class B_Div2_287 {
    public static void main(String[]arg) throws IOException
    {
        new B_Div2_287().solve();
    }
    public void solve()throws IOException
    {
        BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
        StringTokenizer st = new StringTokenizer(in.readLine());
        long ans,r,x,y,xp,yp,d;
        r = Integer.parseInt(st.nextToken());
        x = Integer.parseInt(st.nextToken());
        y = Integer.parseInt(st.nextToken());
        xp = Integer.parseInt(st.nextToken());
        yp = Integer.parseInt(st.nextToken());
        if(x == xp && y == yp)
        {
            System.out.println("0");
        }
        else
        {
            d = (long)Math.ceil(Math.sqrt((x-xp)*(x-xp) + (y-yp)*(y-yp))/(double)(2*r));
            System.out.println(d);
        }
    }
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class B {

	public static void main(String[] args)throws Exception {
		long r=in();
		long x=in();
		long y=in();
		long x1=in();
		long y1=in();
		double d=Math.sqrt((x-x1)*(x-x1)+(y-y1)*(y-y1));
		if (d==0 || d-0<0.00000001){
			System.out.println(0);
			return;
		}
		//System.out.println(d);
		int k=0;
		while (d>=4*r || d-4*r<0.00000001 && d-4*r>-0.00000001){
		//	System.out.println(d);
			k++;
			d-=2*r;
		}
k+=d==2*r||(d-2*r<0.00000001 && d-2*r>-0.00000001)|| d<2*r?1:2;
System.out.println(k);
	}
	static BufferedReader buf=new BufferedReader(new InputStreamReader(System.in));
	static StringTokenizer st;
	static int in() throws IOException{
		if (st==null || !st.hasMoreTokens()){
			st=new StringTokenizer(buf.readLine());
		}
		return Integer.parseInt(st.nextToken());
	}
	static long ll() throws IOException{
		if (st==null || !st.hasMoreTokens()){
			st=new StringTokenizer(buf.readLine());
		}
		return Long.parseLong(st.nextToken());
	}
	static String str() throws IOException{
		if (st==null || !st.hasMoreTokens()){
			st=new StringTokenizer(buf.readLine());
		}
		return (st.nextToken());
	}
		static double dub() throws IOException{
			if (st==null || !st.hasMoreTokens()){
				st=new StringTokenizer(buf.readLine());
			}
			return Double.parseDouble(st.nextToken());
	}
}

import java.util.*;
import java.lang.*;

public class Main
{
	public static void main(String[]args)
	{
		Scanner sc = new Scanner(System.in);
        double r=sc.nextInt();
        double x=sc.nextInt();
        double y=sc.nextInt();
        double x1=sc.nextInt();
        double y1=sc.nextInt();
        double d;
        d=Math.sqrt((x-x1)*(x-x1)+(y-y1)*(y-y1));
        //System.out.println(d);
        //System.out.println(d/r);
        int ans=(int)(d/r);
        if(d%r==0)
        {
            //System.out.println(d%r);
            if((ans)%2==0)
            {
                System.out.print((ans)/2);
            }
            else
            {
                System.out.print(((ans)/2)+1);
            }
        }
        else
        {
            //System.out.println(d%r);
            System.out.print((ans/2)+1);
        }

	}
}

import java.util.Scanner;

public class B507 {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        double r= scanner.nextDouble();
        double x = scanner.nextDouble();
        double y = scanner.nextDouble();
        double x1 = scanner.nextDouble();
        double y1 = scanner.nextDouble();
        double dis =Math.sqrt ((x-x1)*(x-x1) + (y-y1)*(y-y1));
        if(dis == 0){
            System.out.println(0);
        }else if(dis <= 2*r){
            System.out.println(1);
        }else {
            int ans = (int)(dis / (2*r)) ;
            if (2*r * ans  < dis) {
                ans++;
            }
            System.out.println(ans);
        }
    }
}

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

public class Main {

    private  static void solver(InputReader sc, PrintWriter out) {
           int r = sc.nextInt();
           int a = sc.nextInt();
           int b = sc.nextInt();
           int x = sc.nextInt();
           int y = sc.nextInt();
           if(a==x && y==b){
               out.println("0");
               return;
           }
           long x1 = Math.abs(x-a);
           long y1 = Math.abs(y-b);
           x1 *= x1;
           y1 *= y1;
           long sum = x1+y1;
           double dis = Math.sqrt(sum);
          // out.println(x1+" "+y1+" "+dis);
           long ans = (long)Math.ceil(dis/ (2 * r));
           out.println(ans);
    }

    public static void main(String[] args) throws Exception{
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        PrintWriter out = new PrintWriter(outputStream);

        solver(in,out);
        out.close();
    }
    static class InputReader {
        public BufferedReader reader;
        public StringTokenizer tokenizer;

        public InputReader(InputStream stream) {
            reader = new BufferedReader(new InputStreamReader(stream), 32768);
            tokenizer = null;
        }

        public String next() {
            while (tokenizer == null || !tokenizer.hasMoreTokens()) {
                try {
                    tokenizer = new StringTokenizer(reader.readLine());
                } catch (IOException e) {
                    throw new RuntimeException(e);
                }
            }
            return tokenizer.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }
        public long nextLong(){
            return Long.parseLong(next());
        }

        public long[] readLongArr(int n){
            long arr[] = new long[n];
            for(int i=0; i<n; i++){
                arr[i] = nextLong();
            }
            return arr;
        }
        public int[] readIntArr(int n){
            int arr[] = new int[n];
            for(int i=0; i<n; i++){
                arr[i] = nextInt();
            }
            return arr;
        }
    }
}
class Pair{
    long x;
    boolean bool;
    Pair(long x, boolean bool){
        this.x = x;
        this.bool = bool;
    }
}

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

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

import java.util.ArrayList;
import java.util.Iterator;
import java.util.StringTokenizer;

public class C {
    public C() {
        super();
    }

    public static void main(String[] args) throws IOException {
        C c = new C();
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        StringTokenizer st = new StringTokenizer(br.readLine()," ");
        int r = Integer.parseInt(st.nextToken());
        int x = Integer.parseInt(st.nextToken());
        int y = Integer.parseInt(st.nextToken());
        int x1 = Integer.parseInt(st.nextToken());
        int y1 = Integer.parseInt(st.nextToken());

        double diffx = Math.abs(x - x1);
        double diffy = Math.abs(y - y1);

        double res = Math.sqrt(diffx*diffx + diffy*diffy)/(2.0*r);

        StringTokenizer st1  = new StringTokenizer("" + res,".");
        int result = Integer.parseInt(st1.nextToken());
        double residue = Double.parseDouble(st1.nextToken());

        if (residue > 0) {
            result = result + 1;
        }

        System.out.println(result);

    }
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

/**
 * Created by brajesh.k on 15/09/15.
 */
public class Problem507B {
    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String[] line = br.readLine().split(" ");
        long x = Long.parseLong(line[1]) - Long.parseLong(line[3]);
        long y = Long.parseLong(line[2]) - Long.parseLong(line[4]);
        double dis = Math.sqrt(x * x + y * y);
        long dia = Long.parseLong(line[0]) * 2;
        System.out.println((int)(dis / dia) + (dis % dia == 0 ? 0 : 1));
    }
}

import java.io.*;

/**
 * Created by ahmed on 2/13/2016.
 */
public class Main {
    public static void main(String[] args) throws IOException {
        BufferedReader input = new BufferedReader(new InputStreamReader(System.in));
        BufferedWriter output = new BufferedWriter(new OutputStreamWriter(System.out));
        String[] line = input.readLine().split(" ");
        int r = Integer.parseInt(line[0]);
        int x = Integer.parseInt(line[1]);
        int y = Integer.parseInt(line[2]);
        int xn = Integer.parseInt(line[3]);
        int yn = Integer.parseInt(line[4]);
        double distance = (double) Math.sqrt((Math.pow(Math.abs(x - xn), 2) + Math.pow(Math.abs(y - yn), 2)));
        int ans = (int) (distance / (2 * r));
        if(distance % (2 * r) != 0 && distance >= r) {
            ans ++;
        }
        if(distance < r && distance != 0 && (x != xn || y != yn)) {
            ans ++;
        }
//        System.out.println(distance);
        output.write("" + ans);
        output.flush();
    }
}

import java.util.*;

public class AmrPins507B
{
    public static void main(String[] args)
    {
        // Set up scanner
        Scanner sc = new Scanner(System.in);
        // System.out.println("Enter r");
        long r = sc.nextLong();
        // System.out.println("Enter x1");
        long x1 = sc.nextLong();
        // System.out.println("Enter y1");
        long y1 = sc.nextLong();
        // System.out.println("Enter x2");
        long x2 = sc.nextLong();
        // System.out.println("Enter y2");
        long y2 = sc.nextLong();

        double totald = Math.sqrt((x2-x1)*(x2-x1) + (y2-y1)*(y2-y1));
        double times = totald / (r * 2.0);

        long roundit = (long)times;
        if (roundit - times == 0)
        {
            System.out.println((long)times);
        }
        else
        {
            System.out.println((long)(times+1));
        }
    }
}

import java.util.Scanner;

public class ArmAndPins {

    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int r = in.nextInt();
        int x = in.nextInt();
        int y = in.nextInt();
        int xp = in.nextInt();
        int yp = in.nextInt();

        double d = Math.sqrt(Math.pow(xp-x, 2) + Math.pow(yp-y, 2));
        double div = d/(2*r);
        int res = (div - Math.floor(div) < 1e-15) ? (int)div : (int)div + 1;
        System.out.println(res);
    }

}

import java.util.*;

public class ACB {
	public static void main(String args[]) throws Exception {
		//System.out.println("Hiiiii");
		Scanner scn = new Scanner(System.in);
		int r = scn.nextInt();
		int x = scn.nextInt();
		int y = scn.nextInt();
		int x1 = scn.nextInt();
		int y1 = scn.nextInt();
		if (x == x1 && y == y1) {
			System.out.println(0);
		} else {
			double d = Math.pow((Math.pow(x - x1, 2) + Math.pow(y - y1, 2)), 0.5);
			System.out.println((int)Math.ceil(d / (2 * r)));
		}

	}
}

/*

要算出移動最少次	=>	兩個中心點最短距離   / 每次移動最大距離
				(連接兩個中心點的直線)	(2個半徑)
*/
import java.util.*;
public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int r = sc.nextInt();
		int x = sc.nextInt();
		int y = sc.nextInt();
		int x1 = sc.nextInt();
		int y1 = sc.nextInt();

		double d = Math.sqrt(Math.pow(x-x1,2) + Math.pow(y-y1, 2));

		System.out.println((int)Math.ceil(d/(2*r)));
	}
}

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

public class test
{
    public static void main(String[] args) throws IOException
    {
        InputStreamReader inp = new InputStreamReader(System.in);
        BufferedReader br = new BufferedReader(inp);

        String s[] = br.readLine().split(" ");
        double r = Double.parseDouble(s[0]);
        int x1 = Integer.parseInt(s[1]);
        int y1 = Integer.parseInt(s[2]);
        int x2 = Integer.parseInt(s[3]);
        int y2 = Integer.parseInt(s[4]);

        double d =Math.pow (Math.abs(x2-x1),2)+Math.pow(Math.abs(y2-y1),2);
        double q = Math.sqrt(d);

        if(q==0){
        System.out.println("0");

        return;
        }

        double ans = q/(2*r);

        System.out.println((int)Math.ceil(ans));

    }
}

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);

	}

}

import java.util.*;

public class Length {
    public static int min = 0;
    public static int sg = 0;
    public static ArrayList<Integer> arr = new ArrayList<Integer>(1000);
    public static boolean possible = true;
    public static void main(String[] args){
        Scanner in = new Scanner(System.in);
        int r = in.nextInt();
        int x0 = in.nextInt();
        int y0 = in.nextInt();
        int x1 = in.nextInt();
        int y1 = in.nextInt();
        double d = Math.pow(Math.pow(x0-x1,2)+Math.pow(y0-y1,2),0.5);
        int sum = 0;
        int sg = 0;
        while(sg==0){
            if(d==0){
                sg = 1;
            }
            else if(d<2*r){
                sum++;
                sg = 1;
            }
            else {
                d -= 2 * r;
                sum++;
            }
        }
        System.out.println(sum);
    }
}

import java.util.*;
import java.math.*;
import java.io.*;
import java.text.*;
import java.awt.Point;

import static java.util.Arrays.*;
import static java.lang.Integer.*;
import static java.lang.Double.*;
import static java.lang.Long.*;
import static java.lang.Short.*;
import static java.lang.Math.*;
import static java.math.BigInteger.*;
import static java.util.Collections.*;

public class B {

	// IO Imports
	private BufferedReader in;
	private StringTokenizer st;
	private PrintWriter out;

	// Pretty Stuff
	private DecimalFormat fmt = new DecimalFormat("0.0000000000");

	public void solve() throws Exception {
		Scanner sc = new Scanner(System.in);

		int r = sc.nextInt();
		int x1 = sc.nextInt();
		int y1 = sc.nextInt();
		int x2 = sc.nextInt();
		int y2 = sc.nextInt();

		double d = Math.ceil(dist(x1, y1, x2, y2));

		out.println((int)Math.ceil(d/r/2));
	}

	public double dist(long x1, long y1, long x2, long y2) {
		return Math.sqrt((x2 - x1) * (x2 - x1) + (y2 -y1) * (y2 - y1));
	}

	public B() {
		this.in = new BufferedReader(new InputStreamReader(System.in));
		this.out = new PrintWriter(System.out);
	}

	public void end() {
		try {
			this.out.flush();
			this.out.close();
			this.in.close();
		} catch (Exception e) {
			//do nothing then :)
		}
	}

	public static void main(String[] args) throws Exception {
		B solver = new B();
		solver.solve();
		solver.end();
	}
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class ProblemB {
    private static final double DELTA = 1e-14;
    BufferedReader rd;

    private ProblemB() throws IOException {
        rd = new BufferedReader(new InputStreamReader(System.in));
        compute();
    }

    private void compute() throws IOException {
        int[] a = intarr();
        double r = a[0];
        double x = a[1];
        double y = a[2];
        double xd = a[3];
        double yd = a[4];

        double dist = Math.sqrt((xd-x)*(xd-x)+(yd-y)*(yd-y));
        double t = Math.floor((dist / r)*1e14)/1e14;

        int res;
        if(Math.abs(Math.round(t) - t) < DELTA) {
            int z = (int)Math.round(t);
            if(z%2==0) {
                res = z/2;
            } else {
                res = z/2 + 1;
            }
        } else {
            int z = (int)Math.floor(t);
            res = z/2 + 1;
        }
        out(res);
    }

    private int[] intarr() throws IOException {
        return intarr(rd.readLine());
    }

    private int[] intarr(String s) {
        String[] q = split(s);
        int n = q.length;
        int[] a = new int[n];
        for(int i=0;i<n;i++) {
            a[i] = Integer.parseInt(q[i]);
        }
        return a;
    }

    private String[] split(String s) {
        int n = s.length();
        int sp = 0;
        for(int i=0;i<n;i++) {
            if(s.charAt(i)==' ') {
                sp++;
            }
        }
        String[] res = new String[sp+1];
        int last = 0;
        int x = 0;
        for(int i=0;i<n;i++) {
            char c = s.charAt(i);
            if(c == ' ') {
                res[x++] = s.substring(last,i);
                last = i+1;
            }
        }
        res[x] = s.substring(last,n);
        return res;
    }

    private static void out(Object x) {
        System.out.println(x);
    }

    public static void main(String[] args) throws IOException {
        new ProblemB();
    }
}

import java.io.*;
import java.util.*;
import java.math.BigInteger;

public class Main{
    final boolean isFileIO =  false;
    BufferedReader in;
    PrintWriter out;
    StringTokenizer st = new StringTokenizer("");
    String delim = " ";

    public static void main(String[] args) throws IOException {
        Main m = new Main();
        m.initIO();
        m.solve();
        m.in.close();
        m.out.close();
    }

    public void initIO() throws IOException {
        if(!isFileIO) {
            in = new BufferedReader(new InputStreamReader(System.in));
            out = new PrintWriter(System.out);
        } else {
            in = new BufferedReader(new FileReader("input.txt"));
            out = new PrintWriter("output.txt");
        }
    }

    String nextToken() throws IOException {
        if(!st.hasMoreTokens()) {
            st = new StringTokenizer(in.readLine());
        }
        return st.nextToken(delim);
    }

    String readLine() throws IOException {
        return in.readLine();
    }

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

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

    double nextDouble() throws IOException {
        return Double.parseDouble(nextToken());
    }

    public void solve() throws IOException {
        long r, x1, y1, x2, y2;
        r = nextLong(); x1 = nextLong(); y1 = nextLong(); x2 = nextLong(); y2 = nextLong();
        long dist = (x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2);
        long sq = sqrt(dist);
        if(sq == -1) {
            out.println((long)(Math.sqrt((double)dist) / (2 * r)) + 1);
        } else {
            if(sq % (2 * r) == 0) {
                out.println(sq / (2 * r));
            } else {
                out.println(sq / (2 * r) + 1);
            }
        }
    }

    public long sqrt(long a) {
        for(long i = 0; i * i <= a; i++) {
            if(i * i == a) {
                return i;
            }
        }
        return -1;
    }

}

class Utils {

    public static long binpow(long a, long exp, long mod) {
        if(exp == 0) {
            return 1;
        }
        if(exp % 2 == 0) {
            long temp = binpow(a, exp / 2, mod);
            return (temp * temp) % mod;
        } else {
            return (binpow(a, exp - 1, mod) * a) % mod;
        }
    }

    public static long inv(long a, long mod) {
        return binpow(a, mod - 2, mod);
    }

    public static long addmod(long a, long b, long mod) {
        return ((a + b) % mod + mod) % mod;
    }

    public static long gcd(long a, long b) {
        if(b == 0)
            return a;
        return gcd(b, a % b);
    }

    //mul must be < 10^18
    public static long mulmod(long a, long b, long mod) {
        return (a * b + (((a * b) / mod) + 1) * mod) % mod;
    }
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.util.*;

public class AmrAndPins {

    static final double EPS = 1e-9;

    public static void main(String[] args) {
        InputReader in = new InputReader(System.in);

        int r = in.nextInt();
        int x = in.nextInt();
        int y = in.nextInt();
        int xp = in.nextInt();
        int yp = in.nextInt();

        long dx = x - xp;
        long dy = y - yp;

        double d = Math.sqrt(dx * dx + dy * dy) - EPS;

        int ans = (int) Math.ceil(d / (2 * r));

        System.out.println(ans);
    }

    static class InputReader {
        public BufferedReader reader;
        public StringTokenizer tokenizer;

        public InputReader(InputStream stream) {
            reader = new BufferedReader(new InputStreamReader(stream));
            tokenizer = new StringTokenizer("");
        }

        public String next() {
            try {
                while (!tokenizer.hasMoreTokens())
                    tokenizer = new StringTokenizer(reader.readLine());
            } catch (IOException e) {
                throw new RuntimeException(e);
            }

            return tokenizer.nextToken();
        }

        public String nextLine() {
            String line = null;
            try {
                tokenizer = new StringTokenizer("");
                line =  reader.readLine();
            } catch (IOException e) {
                throw new RuntimeException(e);
            }
            return line;
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }

        public double nextDouble() {
            return Double.parseDouble(next());
        }

        public long nextLong() {
            return Long.parseLong(next());
        }

        boolean hasNext() {
            while (!tokenizer.hasMoreTokens()) {
                String line = nextLine();
                if (line == null) return false;
                tokenizer = new StringTokenizer(line);
            }
            return true;
        }
    }
}

import java.util.*;

public class Problem507B {

	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int r = sc.nextInt();
		int x = sc.nextInt();
		int y = sc.nextInt();
		int x1 = sc.nextInt();
		int y1 = sc.nextInt();

		double distance = Math.sqrt(Math.pow(x - x1, 2) + Math.pow(y - y1, 2));
		int minumum = (int) Math.ceil(distance / (2 * r));

		System.out.println(minumum);
	}
}

import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner obj = new Scanner(System.in);
		int r=obj.nextInt(),x1=obj.nextInt(),y1=obj.nextInt(),x2=obj.nextInt(),y2=obj.nextInt();
		double dist =  (Math.pow((x1-x2), 2)+Math.pow((y1-y2), 2));
		dist=Math.sqrt(dist);
		System.out.println((int)Math.ceil(dist/(r*2)));
	}

}

import java.io.BufferedReader;
import java.io.InputStreamReader;

public class Div2_287 {
	public static void main(String[] args)throws Exception{
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String[] in=br.readLine().split(" ");
		long r=Long.parseLong(in[0]);
		long x=Long.parseLong(in[1]);
		long y=Long.parseLong(in[2]);
		long x2=Long.parseLong(in[3]);
		long y2=Long.parseLong(in[4]);

		long dx = Math.abs(x-x2);
		long dy=Math.abs(y-y2);
		double dis = Math.sqrt(dx*dx+dy*dy);
		long total = (long) (dis/(2*r));
		dis-=total*(2*r);
		if(dis!=0)
			total++;

		System.out.println(total);

	}
}

import java.io.InputStreamReader;
import java.io.BufferedReader;
import java.io.IOException;
import java.lang.reflect.Array;
import java.util.Arrays;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Iterator;
import java.util.Map;
import java.util.Set;

    public class Codeforces {

        public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String[] s = br.readLine().trim().split(" ");
        double r = Double.parseDouble(s[0]);
        double x = Double.parseDouble(s[1]);
        double y = Double.parseDouble(s[2]);
        double Xnew = Double.parseDouble(s[3]);
        double Ynew = Double.parseDouble(s[4]);
        int ans = (int)Math.ceil(Math.sqrt((Ynew - y) * (Ynew - y) +(Xnew - x)* (Xnew - x))/(2*r));
        System.out.println(ans);
        }
    }

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class AmrandPins {
public static void main(String[] args) throws IOException {
	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
	StringTokenizer str  = new StringTokenizer(br.readLine());
	double  r = Integer.parseInt(str.nextToken());
	double  x = Integer.parseInt(str.nextToken());
	double  y = Integer.parseInt(str.nextToken());
	double  xx = Integer.parseInt(str.nextToken());
	double  yy = Integer.parseInt(str.nextToken());

	double d = Math.sqrt(Math.pow(Math.abs(x-xx), 2)+Math.pow(Math.abs(y-yy), 2));

	System.out.println((int)Math.ceil(d/(2*r)));

}
}

import java.io.*;
import java.util.*;
import java.text.*;
import java.math.*;
import java.util.regex.*;

public class Main {
    FastScanner in = new FastScanner();
    PrintWriter out;

    public void solve() throws IOException {
        int R = in.nextInt();
        int X = in.nextInt();
        long Y = in.nextInt();
        long Xp = in.nextInt();
        long Yp = in.nextInt();

        long dist = (Xp - X) * (Xp - X) + (Yp - Y) * (Yp - Y);
        if (dist == 0) {
            System.out.println("0");
            return;
        }

        long k = 0;
        while (true) {
            long t = (k + 1) * 2 * R;
            t *= t;
            if (t > dist) {
                break;
            }

            k++;
        }

        long t = k * 2 * R;
        t *= t;
        if (t == dist) {
            System.out.println(k);
        } else {
            System.out.println(k + 1);
        }

    }

    public void run() {
        try {
            solve();
        } catch (IOException e) {
            e.printStackTrace();
        }
    }

    class FastScanner {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        StringTokenizer st;

        String next() {
            while (st == null || !st.hasMoreTokens()) {
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (IOException e) {
                    e.printStackTrace();
                }
            }
            return st.nextToken();
        }

        int nextInt() {
            return Integer.parseInt(next());
        }

        int read() throws IOException {
            return br.read();
        }
    }

    // http://stackoverflow.com/questions/521171/a-java-collection-of-value-pairs-tuples
    public class Pair<L,R> {

      private final L left;
      private final R right;

      public Pair(L left, R right) {
        this.left = left;
        this.right = right;
    }

    public L getLeft() { return left; }
    public R getRight() { return right; }

    @Override
    public int hashCode() { return left.hashCode() ^ right.hashCode(); }

    @Override
    public boolean equals(Object o) {
        if (o == null) return false;
        if (!(o instanceof Pair)) return false;
        Pair pairo = (Pair) o;
        return this.left.equals(pairo.getLeft()) &&
        this.right.equals(pairo.getRight());
    }

}

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

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
//package amr;

import java.util.Scanner;

/**
 *
 * @author Admin
 */
public class Amr {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        Scanner s=new Scanner(System.in);
        double radius = s.nextInt();
        double x1 = s.nextInt();
        double y1 = s.nextInt();
        double x2 = s.nextInt();
        double y2 = s.nextInt();
        double diag=Math.sqrt((x2-x1)*(x2-x1)+(y2-y1)*(y2-y1));
        double steps=0;
        double dis=Math.abs(x2-x1)+Math.abs(y2-y1);
        if(x2-x1 == y2-y1 && y2-y1>0)
            steps=Math.abs(x2-x1)/radius;
        else if(Math.abs(x2-x1) == y2-y1 && y2-y1<0)
            steps=-1*(x2-x1)/radius;
        else if(x2-x1 == y2-y1 && y2-y1 ==0)
            steps=0;
        else if(diag<radius)
            steps=1;
        else { while(diag>0){
            diag=diag-2*radius;
            steps++;
        }
        }

        System.out.println((int)steps);
    }

}

/**
 * @(#)lion.java
 *
 *
 * @author
 * @version 1.00 2015/11/19
 */

import java.io.*;
import java.util.*;
import java.math.*;
public class lion {

    public static void main(String []args) throws IOException{
    	BufferedReader in=new BufferedReader(new InputStreamReader(System.in));
    StringTokenizer st=new StringTokenizer(in.readLine());
    int r=Integer.parseInt(st.nextToken());
    int x1=Integer.parseInt(st.nextToken());
    int y1=Integer.parseInt(st.nextToken());
    int x2=Integer.parseInt(st.nextToken());
    int y2=Integer.parseInt(st.nextToken());
    double dist_x=Math.pow(Math.abs(x2-x1),2);
     double dist_y=Math.pow(Math.abs(y2-y1),2);
    double d=Math.sqrt(dist_y+dist_x);
   // System.out.println(d/(r*2));
    double x=Math.round(d/(r*2));
    if(x*r*2>=d)
    	System.out.println((int)x);
    else{	x++;
    	System.out.println((int)x);
    }}
    }

import java.util.Scanner;

public class TC {

    public static void main(String[] args){
        Scanner in = new Scanner(System.in);

        double r = in.nextInt();
        double x1 = in.nextInt();
        double y1 = in.nextInt();
        double x2 = in.nextInt();
        double y2 = in.nextInt();

        double d = Math.sqrt((x2-x1)*(x2-x1)+(y2-y1)*(y2-y1));
        //System.out.println(d);
        System.out.println((int)Math.ceil(d/(2*r)));
    }
}

import java.util.Scanner;

public class Main {
	static Scanner s;

	public static void main(String[] args) {
		{int n=5;
		int steps=0;
		 s= new Scanner(System.in);
		int a[]=new int[5];

			for(int i=0;i<n;i++)
			{a[i]=s.nextInt();}
			double distance=Math.sqrt(Math.pow(a[3]-a[1], 2)+Math.pow(a[4]-a[2],2));
			//System.out.println(distance);

			if((int)distance==0)
				{steps=0;}
			 else if(distance>0)
			{
			while(distance>0)
			{
			steps++;
			distance=distance-2*a[0];
			}
			}

System.out.println(steps);

		}
	}

}

import java.io.BufferedWriter;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.io.Writer;
import java.util.InputMismatchException;

public class AmrAndPins {
    public static void main(String[] args) {
    InputReader in = new InputReader(System.in);
    OutputWriter out = new OutputWriter(System.out);
    int r = in.readInt();
    int x1 = in.readInt();
    int y1 = in.readInt();
    int x2 = in.readInt();
    int y2 = in.readInt();
    double d = (Math.sqrt(Math.pow((x2 - x1), 2) + Math.pow((y2 - y1), 2)));
    out.print((int) Math.ceil(d / (2 * r)));
    out.close();
    }

    static class InputReader {
    private InputStream stream;
    private byte[] buf = new byte[1024];
    private int curChar;
    private int numChars;

    public InputReader(InputStream stream) {
        this.stream = stream;
    }

    public int read() {
        if (numChars == -1)
        throw new InputMismatchException();
        if (curChar >= numChars) {
        curChar = 0;
        try {
            numChars = stream.read(buf);
        } catch (IOException e) {
            throw new InputMismatchException();
        }
        if (numChars <= 0)
            return -1;
        }
        return buf[curChar++];
    }

    public String readLine() {
        int c = read();
        while (isSpaceChar(c))
        c = read();
        StringBuilder res = new StringBuilder();
        do {
        res.appendCodePoint(c);
        c = read();
        } while (!isEndOfLine(c));
        return res.toString();
    }

    public String readString() {
        int c = read();
        while (isSpaceChar(c))
        c = read();
        StringBuilder res = new StringBuilder();
        do {
        res.appendCodePoint(c);
        c = read();
        } while (!isSpaceChar(c));
        return res.toString();
    }

    public long readLong() {
        int c = read();
        while (isSpaceChar(c))
        c = read();
        int sgn = 1;
        if (c == '-') {
        sgn = -1;
        c = read();
        }
        long res = 0;
        do {
        if (c < '0' || c > '9')
            throw new InputMismatchException();
        res *= 10;
        res += c - '0';
        c = read();
        } while (!isSpaceChar(c));
        return res * sgn;
    }

    public int readInt() {
        int c = read();
        while (isSpaceChar(c))
        c = read();
        int sgn = 1;
        if (c == '-') {
        sgn = -1;
        c = read();
        }
        int res = 0;
        do {
        if (c < '0' || c > '9')
            throw new InputMismatchException();
        res *= 10;
        res += c - '0';
        c = read();
        } while (!isSpaceChar(c));
        return res * sgn;
    }

    public boolean isSpaceChar(int c) {
        return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
    }

    public boolean isEndOfLine(int c) {
        return c == '\n' || c == '\r' || c == -1;
    }
    }

    static class OutputWriter {
    private final PrintWriter writer;

    public OutputWriter(OutputStream outputStream) {
        writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(
            outputStream)));
    }

    public OutputWriter(Writer writer) {
        this.writer = new PrintWriter(writer);
    }

    public void print(Object... objects) {
        for (int i = 0; i < objects.length; i++) {
        if (i != 0)
            writer.print(' ');
        writer.print(objects[i]);
        }
    }

    public void printLine(Object... objects) {
        print(objects);
        writer.println();
    }

    public void close() {
        writer.close();
    }
    }
}

import java.util.Scanner;
public class P507B {
	public static void main(String[] args) {
		Scanner sc=new Scanner(System.in);
		long r=sc.nextLong();
		long x1=sc.nextLong();
		long y1=sc.nextLong();
		long x2=sc.nextLong();
		long y2=sc.nextLong();
		double d=Math.pow(((x2-x1)*(x2-x1)+(y2-y1)*(y2-y1)),0.5);
		System.out.println((long)Math.ceil(d/(2*r)));
	}
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

/**
 * Created by brajesh.k on 15/09/15.
 */
public class Problem507B {
    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String[] line = br.readLine().split(" ");
        long x = Long.parseLong(line[1]) - Long.parseLong(line[3]);
        long y = Long.parseLong(line[2]) - Long.parseLong(line[4]);
        double dis = Math.sqrt(x * x + y * y);
        long dia = Long.parseLong(line[0]) * 2;
        System.out.println((int)(dis / dia) + (dis % dia == 0 ? 0 : 1));
    }
}

//package Code;
import java.util.*;

import java.math.*;
import java.lang.System;
import java.nio.CharBuffer;
import static java.lang.System.*;
import java.io.InputStream;
import java.sql.Time;

public class Main
{
    public static void main(String[] args)
    {
        Double a, b, c, d, i, j, k, m, n;
        Scanner in = new Scanner(System.in);
        m = in.nextDouble();
        a = in.nextDouble();
        b = in.nextDouble();
        c = in.nextDouble();
        d = in.nextDouble();
        n = Math.sqrt(Math.pow(c - a, 2) + Math.pow(d - b, 2));
        m = m * 2.0;
        System.out.println((int)Math.ceil(n/m));
    }
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.StringTokenizer;

public class CF287B {
	private FastScanner in;
	private PrintWriter out;

	class Pair implements Comparable<Pair> {
		int a;
		int b;

		public Pair(int a, int b){
			this.a = a;
			this.b = b;
		}

		public int compareTo(Pair pair){
			int c = Integer.compare(this.a, pair.a);
			if (c != 0){
				return c;
			}
			return Integer.compare(this.b, pair.b);
		}
	}

	public void solve() throws IOException {
		double r = in.nextDouble();
		double x = in.nextDouble();
		double y = in.nextDouble();
		double xx = in.nextDouble();
		double yy = in.nextDouble();
		double dist1 = Math.sqrt((y - yy)*(y - yy) + (x - xx)*(x - xx));
		out.println((int)Math.ceil(dist1/(2.0*r)));
	}

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

	public void run() {
		try {
			in = new FastScanner();
			out = new PrintWriter(System.out);
			solve();
			out.close();
		} catch (IOException e) {
			e.printStackTrace();
		}
	}

	private class FastScanner {
		private BufferedReader br;
		private StringTokenizer st;

		public FastScanner() {
			br = new BufferedReader(new InputStreamReader(System.in));
		}

		public String next() {
			while (st == null || !st.hasMoreTokens()) {
				try {
					st = new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			}
			return st.nextToken();
		}

		public int nextInt() {
			return Integer.parseInt(next());
		}

		public long nextLong() {
			return Long.parseLong(next());
		}

		public double nextDouble() {
			return Double.parseDouble(next());
		}
	}
}

import java.io.FileNotFoundException;
import java.io.InputStreamReader;
import java.io.IOException;
import java.io.FileReader;
import java.io.BufferedReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.util.StringTokenizer;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 * @author Jitendra Kushwaha
 */
public class Main {
	public static void main(String[] args) {
		InputStream inputStream = System.in;
		OutputStream outputStream = System.out;
		FastScanner in = new FastScanner(inputStream);
		PrintWriter out = new PrintWriter(outputStream);
		TaskB solver = new TaskB();
		solver.solve(1, in, out);
		out.close();
	}
}

class TaskB {
    public void solve(int testNumber, FastScanner in, PrintWriter out) {
        int r = in.nextInt();
        int x1 = in.nextInt();
        int y1 = in.nextInt();
        int x2 = in.nextInt();
        int y2 = in.nextInt();

        double dist = Math.sqrt(sq(y2-y1) + sq(x2-x1));

        int res = (int)(dist / (2*r));
        if(dist > res*2*r) ++res;
        out.println(res);
    }

    private long sq(long i) {
        return i*i;
    }
}

class FastScanner {
    BufferedReader br;
    StringTokenizer st;

    public FastScanner(InputStream stream) {
        br = new BufferedReader(new InputStreamReader(stream));
    }

    public String nextToken() {
        while (st == null || !st.hasMoreElements()) {
            try {
                st = new StringTokenizer(br.readLine());
            } catch (IOException e) {
                e.printStackTrace();
            }
        }
        return st.nextToken();
    }

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

}

import java.util.Scanner;
import java.util.*;
public class A490 {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
         Scanner s = new Scanner(System.in);
        int r = s.nextInt();
        int x = s.nextInt();
        int y = s.nextInt();
        int x1 = s.nextInt();
        int y1 = s.nextInt();
        double r1 = Math.sqrt(Math.pow(x-x1,2)+Math.pow(y-y1,2))-r;
        if(x==x1 && y==y1){
            System.out.println(0);
            return;

        }
        if(r1<r){
            System.out.println(1);
            return;
        }
        if(r1/r==0){
            System.out.println(1);
        }else{
            if(r1%r==0){
                System.out.println((r1/r));
            }else{
                System.out.println((int)r1/r);
            }
        }

	}

}

////////////////////---------------------------SHUBHAM CHAUDHARI-------------------------------///////////////////////

import java.util.*;

public class Main {

    static ArrayList<Integer>graph[];
    public static void main(String[] args){
        Scanner in=new Scanner(System.in);
        int r=in.nextInt();
        int x=in.nextInt();
        int y=in.nextInt();
        int xf=in.nextInt();
        int yf=in.nextInt();
        int goalx=Math.abs(x-xf);
        int goaly=Math.abs(y-yf);
        int common=Math.min(goalx,goaly);
        int res=common/r;
        goalx-=common;
        goaly-=common;
        res=res+goalx/(2*r)+goaly/(2*r);
        System.out.println(res);
    }

}

import java.util.Scanner;

public class AmrPins
{
    public static void main(String[] args)
    {
        Scanner in = new Scanner(System.in);
        int d = in.nextInt() * 2 , x1 = in.nextInt() , y1 = in.nextInt() ,
                x2 = in.nextInt() , y2 = in.nextInt();
        int sx = Math.abs(x1 - x2) / d;
        int sy = Math.abs(y1 - y2) / d;
        int rx = Math.abs(x1 - x2) % d;
        int ry = Math.abs(y1 - y2) % d;
        if(rx == 0 || ry == 0)
            System.out.println(sx + sy);
        else
            System.out.println(sx + sy + 1);
    }
}

import java.io.BufferedOutputStream;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.util.StringTokenizer;

public class Pins {

    public static void main(String[] args) {
        Kattio io = new Kattio(System.in,System.out);
        long r=io.getInt();
        int x=io.getInt();
        int y=io.getInt();
        int x2=io.getInt();
        int y2=io.getInt();
        long d=
        Math.abs(x)-Math.abs(x2)*(Math.abs(x)-Math.abs(x2))+
        Math.abs(y)-Math.abs(y2)*(Math.abs(y)-Math.abs(y2));
        int answer=0;
    //  io.println("r:"+r+"  d:"+d);
        while(r*r<d){
            //io.println("r:"+r+"  d:"+d);
            answer++;
            r*=r;
            if(r==1)r++;

        }
        io.println(answer);
        io.close();
    }
static class Kattio extends PrintWriter {

    public Kattio(InputStream i) {
    super(new BufferedOutputStream(System.out));
    r = new BufferedReader(new InputStreamReader(i));
    }
    public Kattio(InputStream i, OutputStream o) {
    super(new BufferedOutputStream(o));
    r = new BufferedReader(new InputStreamReader(i));
    }

    public boolean hasMoreTokens() {
    return peekToken() != null;
    }

    public int getInt() {
    return Integer.parseInt(nextToken());
    }

    public double getDouble() {
    return Double.parseDouble(nextToken());
    }

    public long getLong() {
    return Long.parseLong(nextToken());
    }

    public String getWord() {
    return nextToken();
    }

    private BufferedReader r;
    private String line;
    private StringTokenizer st;
    private String token;

    private String peekToken() {
    if (token == null)
        try {
        while (st == null || !st.hasMoreTokens()) {
            line = r.readLine();
            if (line == null) return null;
            st = new StringTokenizer(line);
        }
        token = st.nextToken();
        } catch (IOException e) { }
    return token;
    }

    private String nextToken() {
    String ans = peekToken();
    token = null;
    return ans;
    }
}
}

import java.util.Scanner;

/**
 * Created by sidharth on 19/9/15.
 */
public class AmrAndPins {
    public static void main(String[] args){

        Scanner sc = new Scanner(System.in);

        int r = sc.nextInt();
        int x = sc.nextInt();
        int y = sc.nextInt();
        int a = sc.nextInt();
        int b = sc.nextInt();

        double xDist = (a - x) * (a - x);
        double yDist = (b - y) * (b - y);
        //System.out.println((xDist + yDist));
        double distance = Math.sqrt(xDist + yDist);

        System.out.println((int) Math.ceil(distance / 2 * r));

    }
}

import java.util.Scanner;

public class AmrPins {

	public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		String[] ss = in.nextLine().split(" ");
		int r, x, y, a, b;
		r = Integer.parseInt(ss[0]);
		x = Integer.parseInt(ss[1]);
		y = Integer.parseInt(ss[2]);
		a = Integer.parseInt(ss[3]);
		b = Integer.parseInt(ss[4]);

		double d = Math.sqrt(Math.pow(a - x, 2.0) + Math.pow(b - y, 2.0));
		double val = d / (2 * r);
		int v = (int) val;
		if ((val - v) > 0.0000001)
			v++;
		System.out.println(v);
		in.close();
	}

}

 import java.util.*;
    import java.lang.Math;
    import java.util.Arrays;
    import java.util.Scanner;
    import java.util.stream.IntStream;
    import java.io.OutputStream;
    import java.io.IOException;
    import java.io.InputStream;
    import java.io.PrintWriter;

    public class Problem {
       	public static void main(String[] args) {
    	   InputStream inputStream = System.in;
            OutputStream outputStream = System.out;
            Scanner in = new Scanner(inputStream);
            PrintWriter out = new PrintWriter(outputStream);
            TaskA solver = new TaskA();
            solver.solve(1, in, out);
            out.close();
    	}

    	static class TaskA {
              public void solve(int testNumber, Scanner in, PrintWriter out) {
                    int r= in.nextInt();
                    int x = in.nextInt();
                    int y = in.nextInt();
                    int x1 = in.nextInt();
                    int y1 = in.nextInt();

                  out.println((int)(Math.ceil(Math.sqrt((x1-x)*(x1-x)+(y1-y)*(y1-y))/(2*r))));

              }
    	}

    public int factorial(int n) {
            int fact = 1;
            int i = 1;
           while(i <= n) {
             fact *= i;
             i++;
           }
            return fact;
    }

    public static int BinarySearch(long temp,long[] sum,int r)
    {
    	int l=0;

    	while(l<=r)
    	{
    		int mid=l+(r-l)/2;
    		if(sum[mid]==temp&&sum[mid]!=-1)
    		{
    		return mid;
    		}
    		if(sum[mid]>temp&&sum[mid]!=-1)
    			r=mid-1;
    		if(sum[mid]<temp&&sum[mid]!=-1)
    			l=mid+1;
        }
    	return -1;
    }
    public static long gcd(long x,long y)
    {
    	if(x%y==0)
    		return y;
    	else
    		return gcd(y,x%y);
    }
    public static int gcd(int x,int y)
    {
    	if(x%y==0)
    		return y;
    	else
    		return gcd(y,x%y);
    }
    public static int abs(int a,int b)
    {
    	return (int)Math.abs(a-b);
    }
    public static long abs(long a,long b)
    {
    	return (long)Math.abs(a-b);
    }
    public static int max(int a,int b)
    {
    	if(a>b)
    		return a;
    	else
    		return b;
    }
    public static int min(int a,int b)
    {
    	if(a>b)
    		return b;
    	else
    		return a;
    }
    public static long max(long a,long b)
    {
    	if(a>b)
    		return a;
    	else
    		return b;
    }
    public static long min(long a,long b)
    {
    	if(a>b)
    		return b;
    	else
    		return a;
    }

    public static long pow(long n,long p,long m)
    {
    	 long  result = 1;
    	  if(p==0)
    	    return 1;
    	if (p==1)
    	    return n;
    	while(p!=0)
    	{
    	    if(p%2==1)
    	        result *= n;
    	    if(result>=m)
    	    result%=m;
    	    p >>=1;
    	    n*=n;
    	    if(n>=m)
    	    n%=m;
    	}
    	return result;
    }
    public static long pow(long n,long p)
    {
    	long  result = 1;
    	  if(p==0)
    	    return 1;
    	if (p==1)
    	    return n;
    	while(p!=0)
    	{
    	    if(p%2==1)
    	        result *= n;
    	    p >>=1;
    	    n*=n;
    	}
    	return result;

    }

    static long sort(int a[]){
         int n=a.length;
    	int b[]=new int[n];
    	return mergeSort(a,b,0,n-1);

    }

    static long mergeSort(int a[],int b[],long left,long right){
         long c=0;
         if(left<right){
          long mid=left+(right-left)/2;
    	 c= mergeSort(a,b,left,mid);
    	 c+=mergeSort(a,b,mid+1,right);
    	 c+=merge(a,b,left,mid+1,right);
         }
    	return c;
    }
    static long merge(int a[],int  b[],long left,long mid,long right){
         long c=0;int i=(int)left;int j=(int)mid; int k=(int)left;
         while(i<=(int)mid-1&&j<=(int)right){
              if(a[i]<=a[j]){
                   b[k++]=a[i++];
              }
              else{
                   b[k++]=a[j++];c+=mid-i;
              }
         }

         while (i <= (int)mid - 1)
                 b[k++] = a[i++];
         while (j <= (int)right)
                 b[k++] = a[j++];
         for (i=(int)left; i <= (int)right; i++)
    	        a[i] = b[i];
    	        return c;
         }

    }

import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int[] stevila = new int[5];
        for (int i = 0; i < 5; i++) {
            stevila[i] = scanner.nextInt();
        }

        float d = (float)Math.sqrt(Math.pow((stevila[3] - stevila[1]),2) + Math.pow((stevila[4] - stevila[2]),2));

        if (d % stevila[0] != 0)
            System.out.println(((int)d/(2*stevila[0])) + 1);
        else
            System.out.println((int)d/(2*stevila[0]));

    }
}

import java.util.*;
import java.io.*;
public class rotac{
public static void main(String args[]) throws IOException{
BufferedReader lector = new BufferedReader(new InputStreamReader(System.in));
String tmp[] = lector.readLine().split(" ");
int r = Integer.parseInt(tmp[0]);
int x1 = Integer.parseInt(tmp[1]);
int y1 = Integer.parseInt(tmp[2]);
int x2= Integer.parseInt(tmp[3]);
int y2 = Integer.parseInt(tmp[4]);
double hh = Math.hypot(x1-x2,y1-y2);
double h = hh-2*r;
//System.out.println(hh);
if(h<0.0){
System.out.println(hh!=0.0?2:0);
return;
}
int d = (int)Math.floor(h/(2.0*r));
System.out.println(d+1);
}
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.util.StringTokenizer;

public class CF {

    public static void main(String[] args) throws IOException {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        int r = in.nextInt();
        int x = in.nextInt();
        int y = in.nextInt();
        int x1 = in.nextInt();
        int y1 = in.nextInt();
        double d=Math.sqrt((x-x1)*(x-x1)+(y-y1)*(y-y1));
         int l=(int)(d/(2*r));
        if(d%(2*r)==0) out.println(l);

        else    out.println(l+1);

        out.close();
    }

}

class InputReader {

    public BufferedReader reader;
    public StringTokenizer tokenizer;

    public InputReader(InputStream stream) {
        reader = new BufferedReader(new InputStreamReader(stream), 32768);
        tokenizer = null;
    }
 public String nextLine() {
            try {
                return reader.readLine();
            } catch (IOException e) {
                // TODO Auto-generated catch block
                e.printStackTrace();
                return null;
            }
        }

    public String next() {
        while (tokenizer == null || !tokenizer.hasMoreTokens()) {
            try {
                tokenizer = new StringTokenizer(reader.readLine());
            } catch (IOException e) {
                throw new RuntimeException(e);
            }
        }
        return tokenizer.nextToken();
    }

    public int nextInt() {
        return Integer.parseInt(next());
    }

}

import java.io.InputStreamReader;
import java.io.IOException;
import java.io.BufferedReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.util.StringTokenizer;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 */
public class Main {
	public static void main(String[] args) {
		InputStream inputStream = System.in;
		OutputStream outputStream = System.out;
		InputReader in = new InputReader(inputStream);
		PrintWriter out = new PrintWriter(outputStream);
		TaskB solver = new TaskB();
		solver.solve(1, in, out);
		out.close();
	}
}

class TaskB {
    public void solve(int testNumber, InputReader in, PrintWriter out) {
        long r = in.nextInt();
        long x = in.nextInt();
        long y = in.nextInt();
        long x1 = in.nextInt();
        long y1 = in.nextInt();

        long od = (x1 - x) * (x1 - x) + (y1 - y) * (y1 - y);
        boolean within = false;
        if (od < r * r) {
            within = true;
        }

        double ods = Math.sqrt((double) od);
        double eps = 1e-9;
        double ans = (ods / r) + eps;
        long a = (long) ans;
        if (a*a < ods){
            a++;
        }
        if (within) {
            if (x1 == x && y1 == y) {
                out.println(0);
            } else {
                out.println(1);
            }
            return;
        }
        out.println(a-1);
    }
}

class InputReader {
    public BufferedReader reader;
    public StringTokenizer tokenizer;

    public InputReader(InputStream stream) {
        reader = new BufferedReader(new InputStreamReader(stream), 32768);
        tokenizer = null;
    }

    public String next() {
        while (tokenizer == null || !tokenizer.hasMoreTokens()) {
            try {
                tokenizer = new StringTokenizer(reader.readLine());
            } catch (IOException e) {
                throw new RuntimeException(e);
            }
        }
        return tokenizer.nextToken();
    }

    public int nextInt() {
        return Integer.parseInt(next());
    }
}

/* package whatever; // don't place package name! */

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

/* Name of the class has to be "Main" only if the class is public. */
public final class Ideone
{
	public static void main (String[] args) throws java.lang.Exception
	{
		// your code goes here
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String s1[] = br.readLine().split(" ");
		int r = Integer.parseInt(s1[0]);
		double x = Integer.parseInt(s1[1]);
		double y = Integer.parseInt(s1[2]);
		double x1 = Integer.parseInt(s1[3]);
		double y1 = Integer.parseInt(s1[4]);
		if(x1 < 0 && y1 < 0 && x>0 && y >0){
			x1 = x1 * -1;
			y1 = y1 * -1;
		}
		double z =Math.ceil(((x1 - x) + (y1 - y))/ (2 * r));
		int q = (int)(z);
		System.out.println(q);

	}
}

//package codeforces;

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.Comparator;
import java.util.HashMap;
import java.util.List;
import java.util.Locale;
import java.util.Map;
import java.util.StringTokenizer;

public class B {
    BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
    PrintWriter writer = new PrintWriter(System.out);
    StringTokenizer stringTokenizer;

    B() throws IOException {
//        reader = new BufferedReader(new FileReader("cycle2.in"));
//        writer = new PrintWriter(new FileWriter("cycle2.out"));
    }

    String next() throws IOException {
        while (stringTokenizer == null || !stringTokenizer.hasMoreTokens()) {
            stringTokenizer = new StringTokenizer(reader.readLine());
        }
        return stringTokenizer.nextToken();
    }

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

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

    double nextDouble() throws IOException {
        return Double.parseDouble(next());
    }

    int[][] mul(int[][] a, int[][] b) {
        int[][] result = new int[2][2];
        for (int i = 0; i < 2; i++) {
            for (int j = 0; j < 2; j++) {
                for (int k = 0; k < 2; k++) {
                    result[i][j] = sum(result[i][j], product(a[i][k], b[k][j]));
                }
            }
        }
        return result;
    }

    int[][] pow(int[][] a, int k) {
        int[][] result = {{1, 0}, {0, 1}};
        while (k > 0) {
            if (k % 2 == 1) {
                result = mul(result, a);
            }
            a = mul(a, a);
            k /= 2;
        }
        return result;
    }

    final int MOD = 1000 * 1000 * 1000 + 7;

    int sum(int a, int b) {
        a += b;
        return a >= MOD ? a - MOD : a;
    }

    int product(int a, int b) {
        return (int) (1l * a * b % MOD);
    }

    @SuppressWarnings("unchecked")
    void solve() throws IOException {
        int r = nextInt();
        int x1 = nextInt();
        int y1 = nextInt();
        int dx = nextInt() - x1;
        int dy = nextInt() - y1;
        double d = Math.sqrt(1.0 * dx * dx + 1.0 * dy * dy);
        long k = (long)(Math.floor(d / r) + 0.1);
        double rem = d - 1.0 * k * r;
        long ans = k / 2;
        if(Math.abs(rem) > 1e-7) {
            ans++;
        }
        writer.println(ans);
        writer.close();
    }

    public static void main(String[] args) throws IOException {
        new B().solve();
    }

}

import java.util.Scanner;

public class HELLLLL {

	public static void main(String[] args) {
		long b,c,d,e,f = 0,g;
		float a;
		Scanner scan=new Scanner(System.in);
		a=scan.nextInt();
		b=scan.nextInt();
		c=scan.nextInt();
		d=scan.nextInt();
		e=scan.nextInt();
		if((b==d)&&(c==e))
		System.out.println("0");
		else
			{f=(int) Math.ceil((float)Math.sqrt(((b-d)*(b-d))+((c-e)*(c-e))));
		System.out.println(f);
			g=(int) Math.ceil((f-2*a)/(2*a));
			System.out.println(g);
			System.out.println(++g);
			}

	}
	}

import java.util.Scanner;

public class prob3 {

	public static long generer(int r,int x,int y,int x1,int y1)
	{
		long res;

		/*int res=( Math.abs(x-x1)-(Math.abs(x-x1)%(2*r)) )/(2*r);

		res+=( Math.abs(y-y1)-(Math.abs(y-y1)%(2*r)) )/(2*r);

		if(Math.abs(x-x1)%(2*r)!=0 || Math.abs(y-y1)%(2*r)!=0 )
			res++;*/

		long distance=(long) (Math.pow((x-x1),2)+Math.pow((y-y1),2));
		distance=(long) Math.sqrt(distance);
		res=(distance-(distance%r))/(2*r);
		if(distance%r!=0)
		res++;

		return res;
	}

	public static void main(String[] args) {

		Scanner sc=new Scanner(System.in);
		int r=sc.nextInt();
		int x=sc.nextInt();
		int y=sc.nextInt();
		int x1=sc.nextInt();
		int y1=sc.nextInt();

		System.out.println(generer(r,x,y,x1,y1));
	}

}

import java.util.*;
import java.io.*;
public class B
{
	public static void main(String J[])
	{
		int r,x,y,x1,y1,rx,ry;
		Scanner in=new Scanner(System.in);
		r=in.nextInt();
		x=in.nextInt();
		y=in.nextInt();
		x1=in.nextInt();
		y1=in.nextInt();
		rx=Math.abs(x1-x);
		ry=Math.abs(y1-y);
		int res=(rx+ry)/(r*2);
		System.out.println(res);
	}
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Code507B {

	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

		String[] input = br.readLine().split(" ");

		int r = Integer.parseInt(input[0]);
		int x = Integer.parseInt(input[1]);
		int y = Integer.parseInt(input[2]);
		int x_p = Integer.parseInt(input[3]);
		int y_p = Integer.parseInt(input[4]);

		int x_move = (int) Math.pow(Math.abs(x - x_p), 2);
		int y_move = (int) Math.pow(Math.abs(y - y_p), 2);

		int count = 0;
		int moveDist = 2 * r;

		while(Math.pow(count * moveDist, 2) < x_move + y_move) {
			count++;
		}

		System.out.println(count);

	}

}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.util.*;

public class AmrAndPins {
    public static void main(String[] args) {
        InputReader in = new InputReader(System.in);

        int r = in.nextInt();
        int x = in.nextInt();
        int y = in.nextInt();
        int xp = in.nextInt();
        int yp = in.nextInt();

        int dx = x - xp;
        int dy = y - yp;

        double d = Math.sqrt(dx * dx + dy * dy);

        int ans = (int) Math.ceil(d / (2 * r));

        System.out.println(ans);
    }

    static class InputReader {
        public BufferedReader reader;
        public StringTokenizer tokenizer;

        public InputReader(InputStream stream) {
            reader = new BufferedReader(new InputStreamReader(stream));
            tokenizer = new StringTokenizer("");
        }

        public String next() {
            try {
                while (!tokenizer.hasMoreTokens())
                    tokenizer = new StringTokenizer(reader.readLine());
            } catch (IOException e) {
                throw new RuntimeException(e);
            }

            return tokenizer.nextToken();
        }

        public String nextLine() {
            String line = null;
            try {
                tokenizer = new StringTokenizer("");
                line =  reader.readLine();
            } catch (IOException e) {
                throw new RuntimeException(e);
            }
            return line;
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }

        public double nextDouble() {
            return Double.parseDouble(next());
        }

        public long nextLong() {
            return Long.parseLong(next());
        }

        boolean hasNext() {
            while (!tokenizer.hasMoreTokens()) {
                String line = nextLine();
                if (line == null) return false;
                tokenizer = new StringTokenizer(line);
            }
            return true;
        }
    }
}

import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.BufferedReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.io.IOException;
import java.util.StringTokenizer;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 */
public class Main {
	public static void main(String[] args) {
		InputStream inputStream = System.in;
		OutputStream outputStream = System.out;
		InputReader in = new InputReader(inputStream);
		PrintWriter out = new PrintWriter(outputStream);
		TaskB solver = new TaskB();
		solver.solve(1, in, out);
		out.close();
	}
}

class TaskB {
    public void solve(int testNumber, InputReader in, PrintWriter out) {
        int r = in.nextInt();
        int x1 = in.nextInt();
        int y1 = in.nextInt();
        int x2 = in.nextInt();
        int y2 = in.nextInt();

        double dist = Math.sqrt((x1-x2) * (x1-x2) + (y1-y2)*(y1-y2));

        double sol = dist/(2.0*r);

        if (Math.abs((double)Math.round(sol) - sol) <= 0.00000001){
            out.print((Math.round(sol)));
        } else {
            out.println(Math.round(sol + 0.5));
        }
    }
}

class InputReader {
    public BufferedReader reader;
    public StringTokenizer tokenizer;

    public InputReader(InputStream stream){
        reader = new BufferedReader(new InputStreamReader(stream));
    }

    public String next(){
        while (tokenizer == null || !tokenizer.hasMoreTokens()){
            try {
                tokenizer = new StringTokenizer(reader.readLine());
            } catch (IOException e) {
                throw new RuntimeException("FATAL ERROR", e);
            }
        }

        return tokenizer.nextToken();
    }

    public int nextInt(){
        return Integer.valueOf(next());
    }

}

import java.util.Scanner;

public class B {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        long r = sc.nextInt();
        long x = sc.nextInt();
        long y = sc.nextInt();
        long x1 = sc.nextInt();
        long y1 = sc.nextInt();
        long d2 = (x1 - x)*(x1 - x) + (y1 - y)*(y1 - y);
        r *= 2;
        long r2 = r*r;
        long k = d2/r2;
        long c = d2 - k*r2;
        System.out.println((int)(Math.sqrt(k)) + (c > 0 ? 1 : 0));
    }

}

import java.util.Scanner;
import java.util.*;
public class A490 {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
         Scanner s = new Scanner(System.in);
        int r = s.nextInt();
        int x = s.nextInt();
        int y = s.nextInt();
        int x1 = s.nextInt();
        int y1 = s.nextInt();
        double r1 = Math.sqrt(Math.pow(x-x1,2)+Math.pow(y-y1,2))-r;
        if(x==x1 && y==y1){
            System.out.println(0);
            return;

        }
        if(r1<r){
            System.out.println(1);
            return;
        }
        if(r1/r==0){
            System.out.println(1);
        }else{
            if(r1%r==0){
                System.out.println((int)(r1/r));
            }else{
                System.out.println((int)r1/r);
            }
        }

	}

}

import java.util.Scanner;
public class B {
	public static void main(String args[]) {
		Scanner in = new Scanner(System.in);
		int r = in.nextInt();
		int a[] = new int [4];
		for (int i=0;i<4;i++) {
			a[i] = in.nextInt();
		}
		if (a[0] == a[2] && a[1] == a[3]) {
			System.out.println(0);
			return;
		} else {
			double dx = a[0] - a[2];
			double dy = a[1] - a[3];
			double distance = Math.sqrt(dx * dx + dy * dy);
			int k = ((int)(distance)) /  ( 2 * r);
			if (Math.abs(distance - (k * 2 * r)) < 0.00001) {
				System.out.println(k);
			} else {
				System.out.println(k + 1);
			}
		}
	}
}

	/**
 * @(#)psv.java
 *
 *
 * @author
 * @version 1.00 2015/11/3
 */
import java.util.*;
import java.io.*;

public class psv {

    public static void main(String [] args) throws IOException{
    	BufferedReader in=new BufferedReader(new InputStreamReader(System.in));
    	StringTokenizer st=new StringTokenizer(in.readLine());
    	int r=Integer.parseInt(st.nextToken());
    	int x=Integer.parseInt(st.nextToken());
    	int y=Integer.parseInt(st.nextToken());
    	int x1=Integer.parseInt(st.nextToken());
    	int y1=Integer.parseInt(st.nextToken());
    //	double distance=Math.sqrt(Math.pow(Math.abs(x1-x),2)+Math.pow(Math.abs(y1-y),2));
    	int count=0;
    	int dist_x=Math.abs(x-x1);
    		int dist_y=Math.abs(y-y1);
    //	System.out.println(distance);
    	while(dist_y>0||dist_x>0){
    		//System.out.println(dist_x);
    		if(dist_x>0){

    			dist_x-=r;
    		}else{

    			dist_y-=r*2;
    			count++;
    			continue;
    					}
    			if(dist_y>0)
    			dist_y-=r;
    			else
    				dist_x-=r;
    		//	System.out.println(dist_x);
    		count++;
    	}//System.out.println(dist_x);

    	System.out.println(count);
    }

}

import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.util.StringTokenizer;

public class B {

    static StringTokenizer st;
    static BufferedReader br;
    static PrintWriter pw;
    public static void main(String[] args) throws IOException {
        br = new BufferedReader(new InputStreamReader(System.in));
        pw = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
        long r = nextInt();
        long x1 = nextInt();
        long y1 = nextInt();
        long x2 = nextInt();
        long y2 = nextInt();
        long d = (x2-x1)*(x2-x1)+(y2-y1)*(y2-y1);
        r *= r;
        long sqrt = (long) Math.sqrt(d);
        long ans = 0;
        if (sqrt * sqrt==d) {
            ans = sqrt / (2*r);
            if (sqrt % (2*r) != 0)
                ans++;
        }
        else
            ans = (long)(Math.sqrt(d) / (2*r)+1e-8) + 1;
        System.out.println(ans);
        pw.close();
    }
    private static int nextInt() throws IOException {
        return Integer.parseInt(next());
    }
    private static long nextLong() throws IOException {
        return Long.parseLong(next());
    }
    private static double nextDouble() throws IOException {
        return Double.parseDouble(next());
    }
    private static String next() throws IOException {
        while (st==null || !st.hasMoreTokens())
            st = new StringTokenizer(br.readLine());
        return st.nextToken();
    }
}

import java.awt.*;
import java.awt.geom.Area;
import java.io.*;
import java.lang.reflect.Array;
import java.math.*;
import java.sql.SQLException;
import java.util.*;
import java.util.Map.Entry;

import javax.management.RuntimeErrorException;

import static java.lang.Math.*;

public class Solution implements Runnable {
        final boolean ONLINE_JUDGE = System.getProperty("ONLINE_JUDGE") != null;
        BufferedReader in;
        PrintWriter out;
        StringTokenizer tok = new StringTokenizer("");
        String delim = " ";

        String readString() throws IOException {
        	try {
	    		while(!tok.hasMoreTokens()) {
	    			tok = new StringTokenizer(in.readLine());
		        }
		        return tok.nextToken(delim);
	    	}
        	catch (Exception e){
        		return null;
	    	}
        }

        int readInt() throws IOException{
            return Integer.parseInt(readString());
        }
        long readLong() throws IOException{
            return Long.parseLong(readString());
        }
        double readDouble() throws IOException{
            return Double.parseDouble(readString());
        }
        Point readPoint() throws IOException {
        	return new Point(readInt(), readInt());
        }
        char readChar() throws IOException{
        	int x = 0;
        	while ((x = in.read()) == '\n' || x == '\r' || x == ' '){ }
        	return (char)x;
        }
//----------------------------------
        public class Three {
            public int a, b, c;
            public Three(){}
            public Three(int a, int b, int c){this.a = a;this.b=b;this.c=c;}
            public String toString(){
                return a + ":" + b + ":" + c;
            }
        }
//----------------------------------------

        void solve() throws IOException {
        	int r = readInt();
        	int x = readInt();
        	int y = readInt();
        	int xx = readInt();
        	int yy = readInt();

        	long length = (xx - x)*1l*(xx - x) + (yy - y)*1l*(yy - y);
        	long rr = r*1l*r;

        	long del = (long)Math.sqrt(length/rr);
        	if (length % rr != 0){
        		del++;
        	}

        	out.print(del);
        }

//----------------------------------------
        public static void main(String[] args){
            new Thread(null, new Solution(), "", 256 * (1L << 20)).start();
        }

        public void run(){
                try{
                        timeBegin = System.currentTimeMillis();

                        try{
                            if (ONLINE_JUDGE){
                                in = new BufferedReader(new InputStreamReader(System.in));
                                out = new PrintWriter(System.out);
                            }
                            else {
                            	in = new BufferedReader(new FileReader("input.txt"));
                            	out = new PrintWriter("output.txt");
                            }
                        }catch(Throwable e){
                            in = new BufferedReader(new InputStreamReader(System.in));
                            out = new PrintWriter(System.out);
                        }

                        solve();
                        out.close();

                        timeEnd = System.currentTimeMillis();
                        System.err.println("Time = " + (timeEnd - timeBegin));
                }catch (Exception e){
                        e.printStackTrace(System.err);
                        System.exit(-1);
                }
        }

        long timeBegin, timeEnd;
}

import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		long r2 = 2 * in.nextInt();
		long x = in.nextInt();
		long y = in.nextInt();
		long x1 = in.nextInt();
		long y1 = in.nextInt();
		long R = (x-x1)*(x-x1)+(y-y1)*(y-y1);
		double distance =  Math.sqrt(R);

		long times = (long) distance/r2;
		if (times * times == distance || (times+1)*(times+1) == distance) {
			System.out.println(times);
		} else {
			System.out.println(times + 1);
		}
	}

}

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

public class Template {

	static Scanner sc = new Scanner(System.in);

	public static void main(String[] args) {
		int r = sc.nextInt();
		int x0 = sc.nextInt(), y0 = sc.nextInt(), x1 = sc.nextInt(), y1 = sc.nextInt();

		double dist = Math.sqrt((y1-y0)*(y1-y0) + (x1-x0)*(x1-x0));

		int moves = (int) Math.ceil(dist/2/r);
		System.out.println(moves);
	}

	public static int[] readArray(int n) {
		int[] a = new int[n];
		for(int i=0 ; i<n ; i++) {
			a[i] = sc.nextInt();
		} return a;
	}

	public static String giveBinary(long n) {
		StringBuffer sb = new StringBuffer();
		for(int i=20 ; i>=0 ; i--) {
			if(n>=Math.pow(2,i)) {
				n-= Math.pow(2, i);
				sb.append("1");
			}else sb.append("0");
		}
		return sb.toString();
	}

	public static int gcd(int a , int b) {
		if(a==0) return b;
		else return gcd(b%a,a);
	}

	public static boolean isPrime(long n) {
		for(int i=2 ; i*i<=n ; i++) {
			if(n%i==0) return false;
		}
		return true;
	}

}

//package codeForcesTry;

import java.io.BufferedReader;
import java.io.Closeable;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.StringTokenizer;

public class B509_AmrPins implements Closeable {
	BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
    PrintWriter writer = new PrintWriter(System.out);
    StringTokenizer stringTokenizer;

    String next() throws IOException {
        while (stringTokenizer == null || !stringTokenizer.hasMoreTokens()) {
            stringTokenizer = new StringTokenizer(reader.readLine());
        }
        return stringTokenizer.nextToken();
    }

    double nextDouble() throws IOException {
        return Double.parseDouble(next());
    }

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

    long nextLong() throws IOException {
        return Long.parseLong(next());
    }
    public void solve()throws IOException {
    	int r,x,y,x1,y1;
    	r=nextInt();x=nextInt();y=nextInt();x1=nextInt();y1=nextInt();
    	long xy=(x-x1)*(x-x1)+(y-y1)*(y-y1);
    	double dist=Math.sqrt(xy);

    	int i=1;

    	while(r*2*i<=dist){
    		i++;
    	}
    	if(dist==0){
    		i=0;
    	}
    	writer.println(i);
    }
    public static void main(String args[]) throws IOException{
    	try(B509_AmrPins c=new B509_AmrPins()){
    	c.solve();
    	}
    }
    public void close() throws IOException {
        reader.close();
        writer.close();
    }

}

import static java.lang.System.in;

import java.io.IOException;

public class B287 {

    static byte[] buffer = new byte[8192];
    static int offset = 0;
    static int bufferSize = 0;
    public static void main(String args[])throws IOException
    {
        long r = readLong();
         long x =readLong();
        long y =readLong();
        long a =readLong();
        long b = readLong();
        double dist = Math.sqrt((x-a)*(x-a) + (y-b)*(y-b));
        double di = (int)(dist);
        long r1 = (int)di;
        long ans  = r1/(2*r);
        System.out.println(dist +" " +di);
        if (x==a && y==b)
        {
            System.out.println(0);
            return;
        }
        if (r1%(2*r)==0 && Double.compare(dist, di)!=0)
            ans++;
        else if (r1%(2*r)!=0 && Double.compare(dist, di)!=0)
            ans++;
        else if (r1%(2*r)!=0 && Double.compare(dist, di)==0)
            ans++;
        System.out.println(ans);

    }

    static int readInt() throws IOException{
        int number = 0;
        int s =1;
        if(offset==bufferSize){
            offset = 0;
            bufferSize = in.read(buffer);
        }
        for(;buffer[offset]<0x30 || buffer[offset]=='-'; ++offset)
        {
            if (buffer[offset]=='-')
                s=-1;
            if(offset==bufferSize-1 ){
                offset=-1;
                bufferSize = in.read(buffer);
            }
        }
        for(;offset<bufferSize && buffer[offset]>0x2f;++offset){
            number = number*0x0a+buffer[offset]-0x30;
            if(offset==bufferSize-1){
                offset = -1;
                bufferSize = in.read(buffer);
            }
        }
        ++offset;
        return number*s;
    }

    static long readLong() throws IOException{
        long number = 0;
        long s=1;
        if(offset==bufferSize){
            offset = 0;
            bufferSize = in.read(buffer);
        }
        for(;buffer[offset]<0x30; ++offset)
        {
            if (buffer[offset]=='-')
                s=-1;
            if(offset==bufferSize-1){
                offset=-1;
                bufferSize = in.read(buffer);
            }
        }
        for(;offset<bufferSize && buffer[offset]>0x2f;++offset){
            number = number*0x0a+buffer[offset]-0x30;
            if(offset==bufferSize-1){
                offset = -1;
                bufferSize = in.read(buffer);
            }
        }
        ++offset;
        return number*s;
    }

}

import java.util.Scanner;

public class Test {
	public static void main(String[] args) {

		Scanner in = new Scanner(System.in);

		String input = in.nextLine();

		String[] split = input.split(" ");

		int radius = Integer.parseInt(split[0]);

		int xSource = Integer.parseInt(split[1]);

		int ySource = Integer.parseInt(split[2]);

		int xDestination = Integer.parseInt(split[3]);

		int yDestination = Integer.parseInt(split[4]);

		double xDiff = Math.pow((double)(xDestination - xSource), 2);

		double yDiff = Math.pow((double)(yDestination - ySource), 2);

		double distance = Math.sqrt(xDiff + yDiff);

		double nSteps = 0;

		if(distance % radius == 0)
		{
			nSteps = distance/radius - 1;
		}

		else
		{
			nSteps = distance/radius - 1;

			nSteps = (int)nSteps;
		}

		if(nSteps < 0)
		{
			nSteps = 0;
		}

		int xSteps = (xDestination - xSource)/(radius*2);

		int ySteps = (yDestination - ySource)/(radius*2);

		int totalSteps = 0;

		if(distance % radius == 0)
		{
			totalSteps = xSteps + ySteps;
		}

		else
		{
			totalSteps = xSteps + ySteps + 1;
		}

		if(totalSteps < 0)
		{
			totalSteps = totalSteps + 1;
			totalSteps = Math.abs(totalSteps);
		}

		//System.out.println((int)nSteps);

		System.out.println(totalSteps);
	}
}

import java.awt.*;
import java.awt.geom.Area;
import java.io.*;
import java.lang.reflect.Array;
import java.math.*;
import java.sql.SQLException;
import java.util.*;
import java.util.Map.Entry;

import javax.management.RuntimeErrorException;

import static java.lang.Math.*;

public class Solution implements Runnable {
        final boolean ONLINE_JUDGE = System.getProperty("ONLINE_JUDGE") != null;
        BufferedReader in;
        PrintWriter out;
        StringTokenizer tok = new StringTokenizer("");
        String delim = " ";

        String readString() throws IOException {
        	try {
	    		while(!tok.hasMoreTokens()) {
	    			tok = new StringTokenizer(in.readLine());
		        }
		        return tok.nextToken(delim);
	    	}
        	catch (Exception e){
        		return null;
	    	}
        }

        int readInt() throws IOException{
            return Integer.parseInt(readString());
        }
        long readLong() throws IOException{
            return Long.parseLong(readString());
        }
        double readDouble() throws IOException{
            return Double.parseDouble(readString());
        }
        Point readPoint() throws IOException {
        	return new Point(readInt(), readInt());
        }
        char readChar() throws IOException{
        	int x = 0;
        	while ((x = in.read()) == '\n' || x == '\r' || x == ' '){ }
        	return (char)x;
        }
//----------------------------------
        public class Three {
            public int a, b, c;
            public Three(){}
            public Three(int a, int b, int c){this.a = a;this.b=b;this.c=c;}
            public String toString(){
                return a + ":" + b + ":" + c;
            }
        }
//----------------------------------------

        void solve() throws IOException {
        	int r = readInt();
        	int x = readInt();
        	int y = readInt();
        	int xx = readInt();
        	int yy = readInt();

        	long length = (xx - x)*1l*(xx - x) + (yy - y)*1l*(yy - y);
        	long rr = r*1l*r;

        	long del = (long)Math.sqrt(length/rr)-1;
        	if (length % rr != 0){
        		del++;
        	}

        	out.print(del);
        }

//----------------------------------------
        public static void main(String[] args){
            new Thread(null, new Solution(), "", 256 * (1L << 20)).start();
        }

        public void run(){
                try{
                        timeBegin = System.currentTimeMillis();

                        try{
                            if (ONLINE_JUDGE){
                                in = new BufferedReader(new InputStreamReader(System.in));
                                out = new PrintWriter(System.out);
                            }
                            else {
                            	in = new BufferedReader(new FileReader("input.txt"));
                            	out = new PrintWriter("output.txt");
                            }
                        }catch(Throwable e){
                            in = new BufferedReader(new InputStreamReader(System.in));
                            out = new PrintWriter(System.out);
                        }

                        solve();
                        out.close();

                        timeEnd = System.currentTimeMillis();
                        System.err.println("Time = " + (timeEnd - timeBegin));
                }catch (Exception e){
                        e.printStackTrace(System.err);
                        System.exit(-1);
                }
        }

        long timeBegin, timeEnd;
}

import java.util.*;
import java.io.*;
import java.lang.*;
import java.math.*;
public class B {
    public static void main(String[] args) throws Exception {
        BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
        StringTokenizer st = new StringTokenizer(bf.readLine());
        int r = Integer.parseInt(st.nextToken());
        int x = Integer.parseInt(st.nextToken());
        int y = Integer.parseInt(st.nextToken());
        int x1 = Integer.parseInt(st.nextToken());
        int y1 = Integer.parseInt(st.nextToken());
        long val = 1L*(x1 - x)*(x1-x) +  1L*(y1 - y)*(y1-y);
        if(val % (4*r*r) == 0) System.out.println(val/(4*r*r));
        else System.out.println((int)Math.ceil(Math.sqrt(val)/(2*r)));
        // Scanner scan = new Scanner(System.in);
        // PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));
        // int n = Integer.parseInt(bf.readLine());
        // StringTokenizer st = new StringTokenizer(bf.readLine());
        // int[] a = new int[n]; for(int i=0; i<n; i++) a[i] = Integer.parseInt(st.nextToken());
        // int n = Integer.parseInt(st.nextToken());
        // int n = scan.nextInt();

        // out.close(); System.exit(0);
    }
}

import java.io.*;

/**
 * Created by DELL on 15-Nov-15.
 */
public class AmrAndPins
{
    public static void main(String arg[])
    {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;

        BufferedReader in = new BufferedReader(new InputStreamReader(inputStream));
        PrintWriter out = new PrintWriter(outputStream);

        try
        {
            String tokens[] = in.readLine().split(" ");
            int diameter = 2 * Integer.parseInt(tokens[0]);
            int x1 = Integer.parseInt(tokens[1]);
            int y1 = Integer.parseInt(tokens[2]);
            int x2 = Integer.parseInt(tokens[3]);
            int y2 = Integer.parseInt(tokens[4]);
            out.println(Math.ceil(Math.sqrt(Math.pow(x1 - x2, 2) + Math.pow(y1 - y2, 2)) / diameter));
        } catch (IOException e)
        {
            e.printStackTrace();
        }
        out.close();
    }
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.StringTokenizer;

public class CF287B {
	private FastScanner in;
	private PrintWriter out;

	class Pair implements Comparable<Pair> {
		int a;
		int b;

		public Pair(int a, int b){
			this.a = a;
			this.b = b;
		}

		public int compareTo(Pair pair){
			int c = Integer.compare(this.a, pair.a);
			if (c != 0){
				return c;
			}
			return Integer.compare(this.b, pair.b);
		}
	}

	public void solve() throws IOException {
		int r = in.nextInt();
		int x = in.nextInt();
		int y = in.nextInt();
		int xx = in.nextInt();
		int yy = in.nextInt();
		if (x == xx && y == yy){
			out.println(0);
			return;
		}
		int num = 0;
		for (int i = 0; i < 200002; i++){
			ArrayList<Pair> a = new ArrayList<Pair>();
			a.add(new Pair(x+r, y+r));
			a.add(new Pair(x+r, y-r));
			a.add(new Pair(x-r, y+r));
			a.add(new Pair(x-r, y-r));
			a.add(new Pair(x+2*r, y));
			a.add(new Pair(x, y+2*r));
			a.add(new Pair(x-2*r, y));
			a.add(new Pair(x, y-2*r));
			Pair bst = a.get(0);
			for (int j = 0; j < a.size(); j++){
				Pair nx = a.get(j);
				double dist1 = Math.sqrt((nx.b - yy)*(nx.b - yy) + (nx.a - xx)*(nx.a - xx));
				double dist2 = Math.sqrt((bst.b - yy)*(bst.b - yy) + (bst.a - xx)*(bst.a - xx));
				if (dist1 < dist2){
					bst = nx;
				}
			}
			x = bst.a;
			y = bst.b;
			num++;
			if (xx == x && yy == y){ out.println(num); return; }
		}
		if (xx != x || yy != y){
			out.println(0);
			return;
		}
		out.println(num);
	}

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

	public void run() {
		try {
			in = new FastScanner();
			out = new PrintWriter(System.out);
			solve();
			out.close();
		} catch (IOException e) {
			e.printStackTrace();
		}
	}

	private class FastScanner {
		private BufferedReader br;
		private StringTokenizer st;

		public FastScanner() {
			br = new BufferedReader(new InputStreamReader(System.in));
		}

		public String next() {
			while (st == null || !st.hasMoreTokens()) {
				try {
					st = new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			}
			return st.nextToken();
		}

		public int nextInt() {
			return Integer.parseInt(next());
		}

		public long nextLong() {
			return Long.parseLong(next());
		}

		public double nextDouble() {
			return Double.parseDouble(next());
		}
	}
}

import java.io.*;
import java.util.*;
import java.nio.charset.StandardCharsets;
// import java.math.BigInteger;

public class B {
    static Writer wr;

    static class State {
        public int u;
        public int v;
        public int d;
        public State(int a, int b, int dd) {
            u = a;
            v = b;
            d = dd;
        }

        public boolean equals(Object obj) {
            if (this == obj)
                return true;
            if (obj == null)
                return false;

            State other = (State)obj;
            if((other.u==u && other.v==v))
            {
                return true;
            }
            return false;
        }

        public int hashCode() {
            final int prime = 31;
            int result = 23;
            result = prime * result + u;
            result = prime * result + v;
            // result = prime * result + w;
            // System.out.print(result + " ");
            return result;
        }
    }

    public static void main(String[] args) throws Exception {
        // long startTime = System.nanoTime();

        // String testString = "";
        // InputStream stream = new ByteArrayInputStream(testString.getBytes(StandardCharsets.UTF_8));
        // Reader in = new Reader(stream);

        Reader in = new Reader();
        BufferedWriter out = new BufferedWriter(new OutputStreamWriter(System.out));

        wr = new Writer();

        /* Precomputation */

        // long elapsedTime = System.nanoTime() - startTime;
        // double seconds = (double)elapsedTime / 1000000000.0;
        // wr.writeRedLn(seconds);

        /* Input */
        int r = in.nextInt();
        int x = in.nextInt();
        int y = in.nextInt();
        int xx = in.nextInt();
        int yy = in.nextInt();

        out.write((long)Math.ceil(Math.sqrt((x-xx)*(x-xx)+(y-yy)*(y-yy))/(2.0d*r)) + "\n");
        out.flush();
    }
}

class Writer {
    public void writeRedLn(Object x) { writeRedLn(x+""); }
    public void writeBlueLn(Object x) { writeBlueLn(x+""); }
    public void writeGreenLn(Object x) { writeGreenLn(x+""); }
    public void writePinkLn(Object x) { writePinkLn(x+""); }
    public void writeRedLn(String x) { System.out.println((char)27 + "[31m" + (char)27 + "[40m" + x + (char)27 + "[0m"); }
    public void writeBlueLn(String x) { System.out.println((char)27 + "[34m" + (char)27 + "[3m" + x + (char)27 + "[0m"); }
    public void writeGreenLn(String x) { System.out.println((char)27 + "[32m" + (char)27 + "[3m" + x + (char)27 + "[0m"); }
    public void writePinkLn(String x) { System.out.println((char)27 + "[30m" + (char)27 + "[45m" + x + (char)27 + "[0m"); }
    public void writeRed(String x) { System.out.print((char)27 + "[31m" + (char)27 + "[40m" + x + (char)27 + "[0m"); }
    public void writeBlue(String x) { System.out.print((char)27 + "[34m" + (char)27 + "[3m" + x + (char)27 + "[0m"); }
    public void writeGreen(String x) { System.out.print((char)27 + "[32m" + (char)27 + "[3m" + x + (char)27 + "[0m"); }
    public void writePink(String x) { System.out.print((char)27 + "[30m" + (char)27 + "[45m" + x + (char)27 + "[0m"); }
}

class Reader {
    public int LINE_LIMIT = -1;
    final private int BUFFER_SIZE = 1 << 16;private DataInputStream din;private byte[] buffer;private int bufferPointer, bytesRead;
    public Reader(){din=new DataInputStream(System.in);buffer=new byte[BUFFER_SIZE];bufferPointer=bytesRead=0;}
    public Reader(InputStream stream){din=new DataInputStream(stream);buffer=new byte[BUFFER_SIZE];bufferPointer=bytesRead=0;}
    public int[] ni_array(int N) throws IOException { int[] ans = new int[N]; for(int i=0;i<N;i++) { ans[i] = nextInt(); } return ans; }
    public String readLineUtil()throws IOException{byte[] buf=new byte[Math.max(400024,LINE_LIMIT)];int cnt=0,c;
        while((c=read())!=-1){if(c=='\n')break;buf[cnt++]=(byte)c;}return new String(buf,0,cnt);}
    public String readLine() throws IOException{ String line = readLineUtil().trim(); while(line.length()==0) line = readLineUtil().trim(); return line; }
    public char nextChar()throws IOException{byte c=read();while(c<=' ')c=read();return (char)c;}
    public int nextInt()throws IOException{int ret=0;byte c=read();while(c<=' ')c=read();boolean neg=(c=='-');
        if(neg)c=read();do{ret=ret*10+c-'0';}while((c=read())>='0'&&c<='9');if(neg)return -ret;return ret;}
    public long nextLong()throws IOException{long ret=0;byte c=read();while(c<=' ')c=read();boolean neg=(c=='-');
        if(neg)c=read();do{ret=ret*10+c-'0';}while((c=read())>='0'&&c<='9');if(neg)return -ret;return ret;}
    public double nextDouble()throws IOException{double ret=0,div=1;byte c=read();while(c<=' ')c=read();boolean neg=(c=='-');if(neg)c = read();do {ret=ret*10+c-'0';}while((c=read())>='0'&&c<='9');
        if(c=='.')while((c=read())>='0'&&c<='9')ret+=(c-'0')/(div*=10);if(neg)return -ret;return ret;}
    private void fillBuffer()throws IOException{bytesRead=din.read(buffer,bufferPointer=0,BUFFER_SIZE);if(bytesRead==-1)buffer[0]=-1;}
    private byte read()throws IOException{if(bufferPointer==bytesRead)fillBuffer();return buffer[bufferPointer++];}
    public void close()throws IOException{if(din==null) return;din.close();}
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.StringTokenizer;

public class CF287B {
	private FastScanner in;
	private PrintWriter out;

	class Pair implements Comparable<Pair> {
		int a;
		int b;

		public Pair(int a, int b){
			this.a = a;
			this.b = b;
		}

		public int compareTo(Pair pair){
			int c = Integer.compare(this.a, pair.a);
			if (c != 0){
				return c;
			}
			return Integer.compare(this.b, pair.b);
		}
	}

	public void solve() throws IOException {
		int r = in.nextInt();
		int x = in.nextInt();
		int y = in.nextInt();
		int xx = in.nextInt();
		int yy = in.nextInt();
		int num = 0;
		for (int i = 0; i < 200002; i++){
			if (x >= xx && y >= yy){
				break;
			}
			ArrayList<Pair> a = new ArrayList<Pair>();
			a.add(new Pair(x+r, y+r));
			a.add(new Pair(x+r, y-r));
			a.add(new Pair(x-r, y+r));
			a.add(new Pair(x-r, y-r));
			a.add(new Pair(x+2*r, y));
			a.add(new Pair(x, y+2*r));
			a.add(new Pair(x-2*r, y));
			a.add(new Pair(x, y-2*r));
			Pair bst = a.get(0);
			for (int j = 0; j < a.size(); j++){
				Pair nx = a.get(j);
				double dist1 = Math.sqrt((nx.b - yy)*(nx.b - yy) + (nx.a - xx)*(nx.a - xx));
				double dist2 = Math.sqrt((bst.b - yy)*(bst.b - yy) + (bst.a - xx)*(bst.a - xx));
				if (dist1 < dist2){
					bst = nx;
				}
			}
			x = bst.a;
			y = bst.b;
			num++;
			if (xx == x && yy == y){ out.println(num); return; }
		}
		if (xx != x && yy != y){
			out.println(0);
			return;
		}
		out.println(num);
	}

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

	public void run() {
		try {
			in = new FastScanner();
			out = new PrintWriter(System.out);
			solve();
			out.close();
		} catch (IOException e) {
			e.printStackTrace();
		}
	}

	private class FastScanner {
		private BufferedReader br;
		private StringTokenizer st;

		public FastScanner() {
			br = new BufferedReader(new InputStreamReader(System.in));
		}

		public String next() {
			while (st == null || !st.hasMoreTokens()) {
				try {
					st = new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			}
			return st.nextToken();
		}

		public int nextInt() {
			return Integer.parseInt(next());
		}

		public long nextLong() {
			return Long.parseLong(next());
		}

		public double nextDouble() {
			return Double.parseDouble(next());
		}
	}
}

import java.util.*;
import java.io.*;
import java.lang.*;
//List<Integer> list = Arrays.stream(number).boxed().collect(Collectors.toList());

public class CFsubmisson
{
    static class FastReader
    {
        BufferedReader br;
        StringTokenizer st;

        public FastReader()
        {
            br = new BufferedReader(new
                     InputStreamReader(System.in));
        }

      public  String next()
        {
            while (st == null || !st.hasMoreElements())
            {
                try
                {
                    st = new StringTokenizer(br.readLine());
                }
                catch (IOException  e)
                {
                    e.printStackTrace();
                }
            }
            return st.nextToken();
        }
         public int nextInt()
        {
            return Integer.parseInt(next());
        }
      public String nextLine()
        {
            String str = "";
            try
            {
                str = br.readLine();
            }
            catch (IOException e)
            {
                e.printStackTrace();
            }
            return str;
        }
    }
    static int setBits(int m)
    {
        int ans=0;
        while(m>0)
        {
        m=m&(m-1);
        ans++;
        }
        return ans;
    }
    static int solve(int A, int B) //Different bits in a&b
    {
    int count = 0;
    for (int i = 0; i < 32; i++)
    {
        if (((A >> i) & 1) != ((B >> i) & 1))
            count++;
     }

    return count;
    }

    public static void main(String[] args)
    {
        FastReader sc=new FastReader();
        int r=sc.nextInt(),x=sc.nextInt(),y=sc.nextInt(),p=sc.nextInt(),q=sc.nextInt();
        long ans=0L;
        int distance=(p-x)*(p-x)+(q-y)*(q-y);
        double rt=Math.sqrt(distance);
        ans=(long)Math.ceil((rt)/(2*r));
        System.out.println(ans);

    }

}

import java.util.*;
import java.lang.*;

public class Main
{
	public static void main(String[]args)
	{
		Scanner sc = new Scanner(System.in);
        int r=sc.nextInt();
        int x=sc.nextInt();
        int y=sc.nextInt();
        int x1=sc.nextInt();
        int y1=sc.nextInt();
        double d;
        d=Math.sqrt((x-x1)*(x-x1)+(y-y1)*(y-y1));
        //System.out.println(d);
        //System.out.println(d/r);
        if(d%r==0)
        {
            System.out.println(d%r);
            if((d/r)%2==0)
            {
                System.out.print((d/r)/2);
            }
            else
            {
                System.out.print(((d/r)/2)+1);
            }
        }
        else
        {
            //System.out.println(d%r);
            int ans=(int)d/r;
            if((ans)%2==0)
            {
                System.out.print(((ans)/2)+1);
            }
            else
            {
                System.out.print(((ans)/2)+2);
            }
        }

	}
}

import java.util.Scanner;

public class Main
{
    public static void main(String[] args)
    {
        Scanner scan = new Scanner(System.in);
        int r , x1 , y1 , x2 , y2 , ans = 0;
        double dist , d;

        r = scan.nextInt();
        x1 = scan.nextInt();
        y1 = scan.nextInt();
        x2 = scan.nextInt();
        y2 = scan.nextInt();

        // 进行处理
        dist = getDist(x1 , y1 , x2 , y2);
        d = 2 * r;

        System.out.println(dist);

        // 如果距离为0
        if (dist == 0)
            System.out.println(0);
        // 如果距离小于等于直径
        else if (dist <= d)
            System.out.println(1);
        // 如果距离大于直径
        else
        {
            while (dist > d)
            {
                dist -= d;
                ans ++;
            }
            // 如果有多余的距离
            if (dist <= d)
                ans ++;
            System.out.println(ans);
        }
    }

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

}

import java.util.Scanner;

public class B {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int r = sc.nextInt();
        int x = sc.nextInt();
        int y = sc.nextInt();
        int x1 = sc.nextInt();
        int y1 = sc.nextInt();
        double d = Math.sqrt((x1 - x)*(x1 - x) + (y1 - y)*(y1 - y));
        r *= 2;
        int d1 = (int)d;
        int k = d1 / r;
        double c = d - k*r;
        double eps = 0.0001;
        System.out.println(k + (c > eps ? 1 : 0));
    }

}

import static java.lang.System.in;

import java.io.IOException;

import java.util.*;

public class Main
{//static{ System.out.println("hello");}
    static byte[] buffer = new byte[8192];
    static int offset = 0;
    static int bufferSize = 0;
    static void print(char a[])
    {for (int i=0;i<a.length ;i++)
        {
         System.out.print(a[i]+"");
           }
   }

        public static void main(String[] args) throws IOException
       {   Scanner scn=new Scanner(System.in);
           int r=readInt();
             int x=readInt();
             int y=readInt();
               int x2=readInt();
                 int y2=readInt();
                 double dist=Math.sqrt(Math.pow(y-y2,2)+Math.pow(x-x2,2));

                 long dist2=(long)dist;
                 int dia=2* r;
                 if (dist2 % dia==0 && dist-dist2==0.0) System.out.println(dist2/dia);
                 else  System.out.println(dist2/dia + 1);
        }
   static int readInt() throws IOException{
        int number = 0;
        if(offset==bufferSize){
            offset = 0;
            bufferSize = in.read(buffer);
        }
        for(;buffer[offset]<0x30; ++offset)
            if(offset==bufferSize-1){
                offset=-1;
                bufferSize = in.read(buffer);
            }
        for(;offset<bufferSize && buffer[offset]>0x2f;++offset){
            number = number*0x0a+buffer[offset]-0x30;
            if(offset==bufferSize-1){
                offset = -1;
                bufferSize = in.read(buffer);
            }
        }
        ++offset;
        return number;
    }

}

import java.awt.*;
import java.awt.geom.Area;
import java.io.*;
import java.lang.reflect.Array;
import java.math.*;
import java.sql.SQLException;
import java.util.*;
import java.util.Map.Entry;

import javax.management.RuntimeErrorException;

import static java.lang.Math.*;

public class Solution implements Runnable {
        final boolean ONLINE_JUDGE = System.getProperty("ONLINE_JUDGE") != null;
        BufferedReader in;
        PrintWriter out;
        StringTokenizer tok = new StringTokenizer("");
        String delim = " ";

        String readString() throws IOException {
        	try {
	    		while(!tok.hasMoreTokens()) {
	    			tok = new StringTokenizer(in.readLine());
		        }
		        return tok.nextToken(delim);
	    	}
        	catch (Exception e){
        		return null;
	    	}
        }

        int readInt() throws IOException{
            return Integer.parseInt(readString());
        }
        long readLong() throws IOException{
            return Long.parseLong(readString());
        }
        double readDouble() throws IOException{
            return Double.parseDouble(readString());
        }
        Point readPoint() throws IOException {
        	return new Point(readInt(), readInt());
        }
        char readChar() throws IOException{
        	int x = 0;
        	while ((x = in.read()) == '\n' || x == '\r' || x == ' '){ }
        	return (char)x;
        }
//----------------------------------
        public class Three {
            public int a, b, c;
            public Three(){}
            public Three(int a, int b, int c){this.a = a;this.b=b;this.c=c;}
            public String toString(){
                return a + ":" + b + ":" + c;
            }
        }
//----------------------------------------

        void solve() throws IOException {
        	int r = readInt();
        	int x = readInt();
        	int y = readInt();
        	int xx = readInt();
        	int yy = readInt();

        	long length = (long)(xx - x)*(xx - x) + (long)(yy - y)*(yy - y);

        	long rr = (long)4*r*r;

        	long del = (long)Math.sqrt((double)length/rr);
        	if (Math.abs(Math.sqrt((double)length/rr) - del) >= 1e-6){
        		del++;
        	}

        	out.print(del);
        }

//----------------------------------------
        public static void main(String[] args){
            new Thread(null, new Solution(), "", 256 * (1L << 20)).start();
        }

        public void run(){
                try{
                        timeBegin = System.currentTimeMillis();

                        try{
                            if (ONLINE_JUDGE){
                                in = new BufferedReader(new InputStreamReader(System.in));
                                out = new PrintWriter(System.out);
                            }
                            else {
                            	in = new BufferedReader(new FileReader("input.txt"));
                            	out = new PrintWriter("output.txt");
                            }
                        }catch(Throwable e){
                            in = new BufferedReader(new InputStreamReader(System.in));
                            out = new PrintWriter(System.out);
                        }

                        solve();
                        out.close();

                        timeEnd = System.currentTimeMillis();
                        System.err.println("Time = " + (timeEnd - timeBegin));
                }catch (Exception e){
                        e.printStackTrace(System.err);
                        System.exit(-1);
                }
        }

        long timeBegin, timeEnd;
}

import java.awt.*;
import java.awt.geom.Area;
import java.io.*;
import java.lang.reflect.Array;
import java.math.*;
import java.sql.SQLException;
import java.util.*;
import java.util.Map.Entry;

import javax.management.RuntimeErrorException;

import static java.lang.Math.*;

public class Solution implements Runnable {
        final boolean ONLINE_JUDGE = System.getProperty("ONLINE_JUDGE") != null;
        BufferedReader in;
        PrintWriter out;
        StringTokenizer tok = new StringTokenizer("");
        String delim = " ";

        String readString() throws IOException {
        	try {
	    		while(!tok.hasMoreTokens()) {
	    			tok = new StringTokenizer(in.readLine());
		        }
		        return tok.nextToken(delim);
	    	}
        	catch (Exception e){
        		return null;
	    	}
        }

        int readInt() throws IOException{
            return Integer.parseInt(readString());
        }
        long readLong() throws IOException{
            return Long.parseLong(readString());
        }
        double readDouble() throws IOException{
            return Double.parseDouble(readString());
        }
        Point readPoint() throws IOException {
        	return new Point(readInt(), readInt());
        }
        char readChar() throws IOException{
        	int x = 0;
        	while ((x = in.read()) == '\n' || x == '\r' || x == ' '){ }
        	return (char)x;
        }
//----------------------------------
        public class Three {
            public int a, b, c;
            public Three(){}
            public Three(int a, int b, int c){this.a = a;this.b=b;this.c=c;}
            public String toString(){
                return a + ":" + b + ":" + c;
            }
        }
//----------------------------------------

        void solve() throws IOException {
        	int r = readInt();
        	int x = readInt();
        	int y = readInt();
        	int xx = readInt();
        	int yy = readInt();

        	long length = (long)(xx - x)*(xx - x) + (long)(yy - y)*(yy - y);

        	long rr = (long)4*r*r;

        	long del = (long)Math.sqrt((double)length/rr);
        	if (Math.abs(Math.sqrt((double)length/rr) - del) >= 1e-5){
        		del++;
        	}

        	out.print(del);
        }

//----------------------------------------
        public static void main(String[] args){
            new Thread(null, new Solution(), "", 256 * (1L << 20)).start();
        }

        public void run(){
                try{
                        timeBegin = System.currentTimeMillis();

                        try{
                            if (ONLINE_JUDGE){
                                in = new BufferedReader(new InputStreamReader(System.in));
                                out = new PrintWriter(System.out);
                            }
                            else {
                            	in = new BufferedReader(new FileReader("input.txt"));
                            	out = new PrintWriter("output.txt");
                            }
                        }catch(Throwable e){
                            in = new BufferedReader(new InputStreamReader(System.in));
                            out = new PrintWriter(System.out);
                        }

                        solve();
                        out.close();

                        timeEnd = System.currentTimeMillis();
                        System.err.println("Time = " + (timeEnd - timeBegin));
                }catch (Exception e){
                        e.printStackTrace(System.err);
                        System.exit(-1);
                }
        }

        long timeBegin, timeEnd;
}

import java.util.Scanner;

public class B {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int r = sc.nextInt();
        int x = sc.nextInt();
        int y = sc.nextInt();
        int x1 = sc.nextInt();
        int y1 = sc.nextInt();
        double d = Math.sqrt((x1 - x)*(x1 - x) + (y1 - y)*(y1 - y));
        r *= 2;
        int d1 = (int)d;
        int k = d1 / r;
        double c = d - k*r;
        System.out.println(k + (c > 0 ? 1 : 0));
    }

}

import java.util.Arrays;

import java.util.Scanner;
import java.util.TreeMap;
import java.util.TreeSet;
import java.io.IOException;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.Comparator;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Hashtable;
import java.util.InputMismatchException;
import java.util.LinkedList;
import java.util.Map;
import java.util.PriorityQueue;
public class R287_2 {
    public static void main(String args[]){
        FasterScanner s=new FasterScanner();
        PrintWriter out=new PrintWriter(System.out);
        int r=s.nextInt();
        int x=s.nextInt();
        int y=s.nextInt();
        int x1=s.nextInt();
        int y1=s.nextInt();
        System.out.println((int)Math.abs(Math.sqrt((x-x1)*(x-x1)+(y-y1)*(y-y1))/(2*r)));
        out.close();
    }

   static class n implements Comparable<n>{
       int id;
       int val;
    @Override
    public int compareTo(n o) {
        return Integer.compare(this.val,o.val);
    }
   }

    public static class FasterScanner {
        private byte[] buf = new byte[1024];
        private int curChar;
        private int numChars;

        public int read() {
            if (numChars == -1)
                throw new InputMismatchException();
            if (curChar >= numChars) {
                curChar = 0;
                try {
                    numChars = System.in.read(buf);
                } catch (IOException e) {
                    throw new InputMismatchException();
                }
                if (numChars <= 0)
                    return -1;
            }
            return buf[curChar++];
        }

        public String nextLine() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            StringBuilder res = new StringBuilder();
            do {
                res.appendCodePoint(c);
                c = read();
            } while (!isEndOfLine(c));
            return res.toString();
        }

        public String nextString() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            StringBuilder res = new StringBuilder();
            do {
                res.appendCodePoint(c);
                c = read();
            } while (!isSpaceChar(c));
            return res.toString();
        }

        public long nextLong() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            long res = 0;
            do {
                if (c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            } while (!isSpaceChar(c));
            return res * sgn;
        }

        public int nextInt() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            int res = 0;
            do {
                if (c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            } while (!isSpaceChar(c));
            return res * sgn;
        }

        public int[] nextIntArray(int n) {
            int[] arr = new int[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }
            return arr;
        }

        public long[] nextLongArray(int n) {
            long[] arr = new long[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextLong();
            }
            return arr;
        }

        private boolean isSpaceChar(int c) {
            return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }

        private boolean isEndOfLine(int c) {
            return c == '\n' || c == '\r' || c == -1;
        }
    }

    public static class disjointSet {

        private int[] parent;  // parent[i] = parent of i
        private byte[] rank;   // rank[i] = rank of subtree rooted at i (never more than 31)
        private int count;     // number of components
        public disjointSet(int N) {
            if (N < 0) throw new IllegalArgumentException();
            count = N;
            parent = new int[N];
            rank = new byte[N];
            for (int i = 0; i < N; i++) {
                parent[i] = i;
                rank[i] = 0;
            }
        }

        public int find(int p) {
            if (p < 0 || p >= parent.length) throw new IndexOutOfBoundsException();
            while (p != parent[p]) {
                parent[p] = parent[parent[p]];    // path compression by halving
                p = parent[p];
            }
            return p;
        }
        public int count() {
            return count;
        }

        public boolean connected(int p, int q) {
            return find(p) == find(q);
        }

        public boolean union(int p, int q) {
            int rootP = find(p);
            int rootQ = find(q);
            if (rootP == rootQ) return false;

            // make root of smaller rank point to root of larger rank
            if      (rank[rootP] < rank[rootQ]) parent[rootP] = rootQ;
            else if (rank[rootP] > rank[rootQ]) parent[rootQ] = rootP;
            else {
                parent[rootQ] = rootP;
                rank[rootP]++;
            }
            count--;
            return true;
        }

    }
}

import java.io.BufferedReader;
import java.io.FileReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.StringTokenizer;

public class Main {

	public static void main(String[] args) throws IOException {
		Scanner sc = new Scanner(System.in);
		PrintWriter out = new PrintWriter(System.out);
		int r, x, y, a, b;
		r = sc.nextInt();
		x = sc.nextInt();
		y = sc.nextInt();
		a = sc.nextInt();
		b = sc.nextInt();

		double dist = Math.sqrt(1L * (x - a) * (x - a) + (y - b) * (y - b));
		int res = (int) (dist / (r << 1));
		if(dist % (r << 1) != 0)
			res++;
		out.println(res);

		out.flush();
		out.close();
	}

	static class Scanner{
		StringTokenizer st;
		BufferedReader br;

		public Scanner(InputStream s){	br = new BufferedReader(new InputStreamReader(s));}

		public Scanner(FileReader r){	br = new BufferedReader(r);}

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

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

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

		public String nextLine() throws IOException {return br.readLine();}

		public double nextDouble() throws IOException { return Double.parseDouble(next()); }

		public boolean ready() throws IOException {return br.ready();}
	}
}

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
//package amr;

import java.util.Scanner;

/**
 *
 * @author Admin
 */
public class Amr {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        Scanner s=new Scanner(System.in);
        int radius = s.nextInt();
        int x1 = s.nextInt();
        int y1 = s.nextInt();
        int x2 = s.nextInt();
        int y2 = s.nextInt();
        double diag=Math.sqrt((x2-x1)*(x2-x1)+(y2-y1)*(y2-y1));
        int steps=0;
        int dis=Math.abs(x2-x1)+Math.abs(y2-y1);
        if(x2-x1 == y2-y1 && y2-y1>0)
            steps=(x2-x1)/radius;
        else if(x2-x1 == y2-y1 && y2-y1<0)
            steps=-1*(x2-x1)/radius;
        else if(x2-x1 == y2-y1 && y2-y1 ==0)
            steps=0;
        else { while(diag>0){
            diag=diag-radius;
            steps++;
        }
        steps--;}

        System.out.println(steps);
    }

}

import java.util.*;
import java.lang.*;
import java.io.*;
public class amrPins{
    public static void main(String[] args) {

        Scanner fi=new Scanner(System.in);
        PrintWriter pr=new PrintWriter(System.out);

        int i=0,j=0;
        int r=fi.nextInt();
        int x=fi.nextInt();
        int y=fi.nextInt();
        int x1=fi.nextInt();
        int y1=fi.nextInt();
        int steps=0;

        int value=(int)Math.pow((x-x1),2)+(int)Math.pow((y-y1),2);
        double dist=Math.sqrt(value);

        if(dist%(2*r)==0)
        {
            if((x==x1)&&(y==y1))
                steps=0;
            else
                steps=(int)(dist/(2*r));
        }
        else
        {
            if(dist>r)
                steps=(int)(dist/(2*r))+1;
            else
                steps=1;
        }

        pr.println(steps);
        fi.close();
        pr.close();

    }

}

 class InputReader {
 private InputStream stream;
 private byte[] buf = new byte[8192];
 private int curChar, snumChars;
 private SpaceCharFilter filter;

 public InputReader(InputStream stream) {
 this.stream = stream;
 }

 public int snext() {
 if (snumChars == -1)
 throw new InputMismatchException();
 if (curChar >= snumChars) {
 curChar = 0;
 try {
 snumChars = stream.read(buf);
 } catch (IOException e) {
 throw new InputMismatchException();
 }
 if (snumChars <= 0)
 return -1;
 }
 return buf[curChar++];
 }

 public int nextInt() {
 int c = snext();
 while (isSpaceChar(c))
 c = snext();
 int sgn = 1;
 if (c == '-') {
 sgn = -1;
 c = snext();
 }
 int res = 0;
 do {
 if (c < '0' || c > '9')
 throw new InputMismatchException();
 res *= 10;
 res += c - '0';
 c = snext();
 } while (!isSpaceChar(c));
 return res * sgn;
 }

 public long nextLong() {
 int c = snext();
 while (isSpaceChar(c))
 c = snext();
 int sgn = 1;
 if (c == '-') {
 sgn = -1;
 c = snext();
 }
 long res = 0;
 do {
 if (c < '0' || c > '9')
 throw new InputMismatchException();
 res *= 10;
 res += c - '0';
 c = snext();
 } while (!isSpaceChar(c));
 return res * sgn;
 }

 public int[] nextIntArray(int n) {
 int a[] = new int[n+1];
 for (int i = 1; i <= n; i++)
 a[i] = nextInt();
 return a;
 }

 public String readString() {
 int c = snext();
 while (isSpaceChar(c))
 c = snext();
 StringBuilder res = new StringBuilder();
 do {
 res.appendCodePoint(c);
 c = snext();
 } while (!isSpaceChar(c));
 return res.toString();
 }

 public boolean isSpaceChar(int c) {
 if (filter != null)
 return filter.isSpaceChar(c);
 return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
 }

 public interface SpaceCharFilter {
 public boolean isSpaceChar(int ch);
 }
 }

import java.util.Scanner;

public class prob3 {

	public static long generer(int r,int x,int y,int x1,int y1)
	{
		long res;
	/*
		res=( Math.abs(x-x1)-(Math.abs(x-x1)%(2*r)) )/(2*r);

		res+=( Math.abs(y-y1)-(Math.abs(y-y1)%(2*r)) )/(2*r);

		if(Math.abs(x-x1)%(2*r)!=0 || Math.abs(y-y1)%(2*r)!=0 )
			res++;*/

		double distance=(Math.pow((x-x1),2)+Math.pow((y-y1),2));
		distance=Math.sqrt(distance);
		res=(long)(distance-(distance%r))/(2*r);
		if(distance%r!=0)
		res++;

		return res;
	}

	public static void main(String[] args) {

		Scanner sc=new Scanner(System.in);
		int r=sc.nextInt();
		int x=sc.nextInt();
		int y=sc.nextInt();
		int x1=sc.nextInt();
		int y1=sc.nextInt();

		System.out.println(generer(r,x,y,x1,y1));
	}

}

import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.io.Writer;
import java.util.InputMismatchException;

public class AmrAndPins {

	public static void main(String[] args) {

		InputReader in = new InputReader(System.in);
		OutputWriter out = new OutputWriter(System.out);
		int r = in.readInt();
		int x = in.readInt();
		int y = in.readInt();
		int x1 = in.readInt();
		int y1 = in.readInt();
		int ans = 0;
		double a = (Math.abs(x1 - x) + Math.abs(y1 - y)) / (2.0 * r);
		out.printLine((int) Math.ceil(a));
		out.close();
	}

	private static class InputReader {
		private InputStream stream;
		private byte[] buf = new byte[1024];
		private int curChar;
		private int numChars;

		public InputReader(InputStream stream) {
			this.stream = stream;
		}

		public int read() {
			if (numChars == -1)
				throw new InputMismatchException();
			if (curChar >= numChars) {
				curChar = 0;
				try {
					numChars = stream.read(buf);
				} catch (IOException e) {
					throw new InputMismatchException();
				}
				if (numChars <= 0)
					return -1;
			}
			return buf[curChar++];
		}

		public long readLong() {
			int c = read();
			while (isSpaceChar(c))
				c = read();
			long sgn = 1;
			if (c == '-') {
				sgn = -1;
				c = read();
			}
			long res = 0;
			do {
				if (c < '0' || c > '9')
					throw new InputMismatchException();
				res *= 10;
				res += c - '0';
				c = read();
			} while (!isSpaceChar(c));
			return res * sgn;
		}

		public int readInt() {
			int c = read();
			while (isSpaceChar(c))
				c = read();
			int sgn = 1;
			if (c == '-') {
				sgn = -1;
				c = read();
			}
			int res = 0;
			do {
				if (c < '0' || c > '9')
					throw new InputMismatchException();
				res *= 10;
				res += c - '0';
				c = read();
			} while (!isSpaceChar(c));
			return res * sgn;
		}

		public String readString() {
			int c = read();
			while (isSpaceChar(c))
				c = read();
			StringBuffer res = new StringBuffer();
			do {
				res.appendCodePoint(c);
				c = read();
			} while (!isSpaceChar(c));
			return res.toString();
		}

		static boolean isSpaceChar(int c) {
			return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
		}

		public String next() {
			return readString();
		}
	}

	private static class OutputWriter {
		private final PrintWriter writer;

		public OutputWriter(OutputStream outputStream) {
			writer = new PrintWriter(outputStream);
		}

		public OutputWriter(Writer writer) {
			this.writer = new PrintWriter(writer);
		}

		public void print(Object... objects) {
			for (int i = 0; i < objects.length; i++) {
				if (i != 0)
					writer.print(' ');
				writer.print(objects[i]);
			}
		}

		public void printLine(Object... objects) {
			print(objects);
			writer.println();
		}

		public void close() {
			writer.close();
		}
	}
}

import java.io.BufferedOutputStream;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStream;

public class AmrAndPins {

    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        OutputStream out = new BufferedOutputStream(System.out);

        String[] l = br.readLine().split("\\s+");
        int r = Integer.parseInt(l[0]);
        int x = Integer.parseInt(l[1]);
        int y = Integer.parseInt(l[2]);
        int x_ = Integer.parseInt(l[3]);
        int y_ = Integer.parseInt(l[4]);

        double d = Math.sqrt(((x - x_) * (x - x_)) + ((y - y_) * (y - y_)));

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

        out.write((res + "\n").getBytes());

        out.flush();
        br.close();

    }

}

import java.util.Scanner;

public class Geometry{

	public static void main(String[] args){
		Scanner sc=new Scanner(System.in);
		final int r=sc.nextInt();
		final int x=sc.nextInt();
		final int y=sc.nextInt();
		final int x1=sc.nextInt();
		final int y1=sc.nextInt();

		int diff=x1+y1-x-y;
		int dia=2*r;
		if(diff%dia==0){
			System.out.println(diff/dia);
		}else{
			System.out.println(diff%dia);
		}

	}
}

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
//package amr;

import java.util.Scanner;

/**
 *
 * @author Admin
 */
public class Amr {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        Scanner s=new Scanner(System.in);
        int radius = s.nextInt();
        int x1 = s.nextInt();
        int y1 = s.nextInt();
        int x2 = s.nextInt();
        int y2 = s.nextInt();
        double diag=Math.sqrt((x2-x1)*(x2-x1)+(y2-y1)*(y2-y1));
        int steps=0;
        int dis=Math.abs(x2-x1)+Math.abs(y2-y1);
        if(x2-x1 == y2-y1 && y2-y1>0)
            steps=(x2-x1)/radius;
        else if(x2-x1 == y2-y1 && y2-y1<0)
            steps=-1*(x2-x1)/radius;
        else if(x2-x1 == y2-y1 && y2-y1 ==0)
            steps=0;
        else if(diag<radius)
            steps=1;
        else { while(diag>0){
            diag=diag-radius;
            steps++;
        }
        steps--;}

        System.out.println(steps);
    }

}

import java.util.*;
import java.io.*;
public class Main  {
    static FastReader in=new FastReader();
    static long mod=1000000007L;

    public static void main(String args[]) throws IOException {
        int t=1;//in.nextInt();
        StringBuilder res=new StringBuilder();
        loop:
        while(t-->0)
        {
           int r=in.nextInt();
           int x1=in.nextInt();
           int y1=in.nextInt();
           int x2=in.nextInt();
           int y2=in.nextInt();
           double dist=Math.ceil(Math.sqrt(Math.abs(x1-x2)*Math.abs(x1-x2)+Math.abs(y1-y2)*Math.abs(y1-y2)));
           res.append((int)Math.ceil(dist/(2*r))+"\n");

        }

        print(res);
    }

    static < E > void print(E res)
    {
        System.out.println(res);
    }

    static  int gcd(int a,int b)
    {
        if(b==0)
        {
            return a;
        }
        return gcd(b,a%b);
    }

    static class FastReader
    {
        BufferedReader br;
        StringTokenizer st;

        public FastReader()
        {
            br = new BufferedReader(new
                    InputStreamReader(System.in));
        }

        String next()
        {
            while (st == null || !st.hasMoreElements())
            {
                try
                {
                    st = new StringTokenizer(br.readLine());
                }
                catch (IOException  e)
                {
                    e.printStackTrace();
                }
            }
            return st.nextToken();
        }
        int nextInt()
        {
            return Integer.parseInt(next());
        }

        long nextLong()
        {
            return Long.parseLong(next());
        }

        double nextDouble()
        {
            return Double.parseDouble(next());
        }
        String nextLine()
        {
            String str = "";
            try
            {
                str = br.readLine();
            }
            catch (IOException e)
            {
                e.printStackTrace();
            }
            return str;
        }

        int [] readintarray(int n) {
            int res [] = new int [n];
            for(int i = 0; i<n; i++)res[i] = nextInt();
            return res;
        }
        long [] readlongarray(int n) {
            long res [] = new long [n];
            for(int i = 0; i<n; i++)res[i] = nextLong();
            return res;
        }
    }

}

import java.util.Scanner;
public class B507{
	public static void main(String args[]){
		Scanner scan = new Scanner(System.in);

		int r, x, y, x1, y1;
		r = scan.nextInt();
		x = scan.nextInt();
		y = scan.nextInt();
		x1 = scan.nextInt();
		y1 = scan.nextInt();

		if(x == x1 && y == y1){
			System.out.println("0");
			System.exit(0);
		}
		//double d = Math.sqrt(Math.pow(x-x1, 2) + Math.pow(y-y1, 2));
		int i = Math.abs(x-x1);
		int j = Math.abs(y-y1);
		int n = i + j;
		if(n % 2 == 0){
			System.out.println(n/(2*r));
			System.exit(0);
		}
		else{
			int a = ((n-1)/2*r)+2;
			System.out.println(a);
		}
	}
}

//package com.infmme.cf507;

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

/**
 * infm created it with love on 1/25/15. Enjoy ;)
 */
public class SolutionB {
	private static double EPS = 0.0000005;

	public static void main(String[] args) {
		FastScanner in = new FastScanner();
		SolutionB.solve(in.nextInt(), in.nextInt(), in.nextInt(), in.nextInt(), in.nextInt());
	}

	public static class FastScanner {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st;

		String next() {
			while (st == null || !st.hasMoreTokens()) {
				try {
					st = new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			}
			return st.nextToken();
		}

		int nextInt() {
			return Integer.parseInt(next());
		}

		int read() throws IOException {
			return br.read();
		}
	}

	public static void solve(long r, long x, long y, long x1, long y1){
		double dist = Math.sqrt((x - x1) * (x - x1) + (y - y1) * (y - y1));
		if (dist < EPS)
			System.out.println(0);
		else if (dist - r < -EPS)
			System.out.println(2);
		else
			System.out.println((int)Math.ceil(dist / r / 2));
	}
}

import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		long r2 = 2 * in.nextInt();
		long x = in.nextInt();
		long y = in.nextInt();
		long x1 = in.nextInt();
		long y1 = in.nextInt();
		long R = (x-x1)*(x-x1)+(y-y1)*(y-y1);
		double distance =  Math.sqrt(R);

		long times = (long) distance/r2;
		if (times * times == distance || (times+1)*(times+1) == distance) {
			System.out.println(times);
		} else {
			System.out.println(times + 1);
		}
	}

}

import java.math.BigInteger;
import java.util.*;
import java.lang.*;
import java.io.*;
/* Name of the class has to be "Main" only if the class is public. */
public class Solution {
    // Complete the maximumSum function below.
    public static class InputReader {
        private InputStream stream;
        private byte[] buf = new byte[1024];
        private int curChar;
        private int numChars;
        private SpaceCharFilter filter;
        private BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

        public InputReader(InputStream stream) {
            this.stream = stream;
        }

        public int read() {
            if (numChars == -1)
                throw new InputMismatchException();

            if (curChar >= numChars) {
                curChar = 0;
                try {
                    numChars = stream.read(buf);
                } catch (IOException e) {
                    throw new InputMismatchException();
                }

                if (numChars <= 0)
                    return -1;
            }
            return buf[curChar++];
        }

        public String nextLine() {
            String str = "";
            try {
                str = br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            return str;
        }

        public int nextInt() {
            int c = read();

            while (isSpaceChar(c))
                c = read();

            int sgn = 1;

            if (c == '-') {
                sgn = -1;
                c = read();
            }

            int res = 0;
            do {
                if (c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            }
            while (!isSpaceChar(c));

            return res * sgn;
        }

        public long nextLong() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            long res = 0;

            do {
                if (c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            }
            while (!isSpaceChar(c));
            return res * sgn;
        }

        public double nextDouble() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            double res = 0;
            while (!isSpaceChar(c) && c != '.') {
                if (c == 'e' || c == 'E')
                    return res * Math.pow(10, nextInt());
                if (c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            }
            if (c == '.') {
                c = read();
                double m = 1;
                while (!isSpaceChar(c)) {
                    if (c == 'e' || c == 'E')
                        return res * Math.pow(10, nextInt());
                    if (c < '0' || c > '9')
                        throw new InputMismatchException();
                    m /= 10;
                    res += (c - '0') * m;
                    c = read();
                }
            }
            return res * sgn;
        }

        public String readString() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            StringBuilder res = new StringBuilder();
            do {
                res.appendCodePoint(c);
                c = read();
            }
            while (!isSpaceChar(c));

            return res.toString();
        }

        public boolean isSpaceChar(int c) {
            if (filter != null)
                return filter.isSpaceChar(c);
            return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }

        public String next() {
            return readString();
        }

        public interface SpaceCharFilter {
            public boolean isSpaceChar(int ch);
        }
    }

    public static long gcd(long a, long b) {
        if (b == 0)
            return a;
        long r = a % b;
        return gcd(b, r);
    }

    static long lcm(long a, long b) {
        return (a * b) / gcd(a, b);
    }

    public class ListNode {
        int val;
        ListNode next;

        ListNode() {
        }

        ListNode(int val) {
            this.val = val;
        }

        ListNode(int val, ListNode next) {
            this.val = val;
            this.next = next;
        }
    }

    public class TreeNode {
        int val;
        TreeNode left;
        TreeNode right;

        TreeNode() {
        }

        TreeNode(int val) {
            this.val = val;
        }

        TreeNode(int val, TreeNode left, TreeNode right) {
            this.val = val;
            this.left = left;
            this.right = right;
        }
    }

    class Node {
        public int val;
        public List<Node> children;

        public Node() {
        }

        public Node(int _val) {
            val = _val;
        }

        public Node(int _val, List<Node> _children) {
            val = _val;
            children = _children;
        }
    }

    static int sumof(long o){
        int s=0;
        while (o>0){
            s+=o%10;
            o/=10;
        }
        return s;
    }

    public static void main(String[] args) throws IOException {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader scanner = new InputReader(inputStream);
        PrintWriter w = new PrintWriter(outputStream);
        int r=scanner.nextInt();
        int x=scanner.nextInt(),y=scanner.nextInt();
        int x1=scanner.nextInt(),y1=scanner.nextInt();
        int dis= (int) Math.sqrt(Math.pow(x-x1,2)+Math.pow(y-y1,2));
        if(dis!=0) {
            if(dis>r)
            w.println((int) Math.ceil((dis - r) * 1.0 / r));
            else
                w.println(1);
        }
        else
            w.println(0);
        w.close();
    }
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class AmrAndPins {

	public static void main(String[] args) {
		MyScanner scan = new MyScanner();
		int r = scan.nextInt();
		int x = scan.nextInt();
		int y = scan.nextInt();
		int x2 = scan.nextInt();
		int y2 = scan.nextInt();

		double distance = Math.sqrt((x2-x)*(x2-x)+(y2-y)*(y2-y));
		System.out.println((int)Math.ceil(distance/(r*2)));
	}

	//-----------MyScanner class for faster input----------
	   public static class MyScanner {
	      BufferedReader br;
	      StringTokenizer st;

	      public MyScanner() {
	         br = new BufferedReader(new InputStreamReader(System.in));
	      }

	      String next() {
	          while (st == null || !st.hasMoreElements()) {
	              try {
	                  st = new StringTokenizer(br.readLine());
	              } catch (IOException e) {
	                  e.printStackTrace();
	              }
	          }
	          return st.nextToken();
	      }

	      int nextInt() {
	          return Integer.parseInt(next());
	      }

	      long nextLong() {
	          return Long.parseLong(next());
	      }

	      double nextDouble() {
	          return Double.parseDouble(next());
	      }

	      String nextLine(){
	          String str = "";
		  try {
		     str = br.readLine();
		  } catch (IOException e) {
		     e.printStackTrace();
		  }
		  return str;
	      }

	   }
	   //--------------------------------------------------------
}

import java.io.IOException;
import java.io.InputStream;
import java.math.BigInteger;
import java.text.DecimalFormat;
import java.util.Arrays;
import java.util.HashMap;
import java.util.InputMismatchException;

public class practiceClass {

	static class Reader {

		private InputStream mIs;
		private byte[] buf = new byte[1024];
		private int curChar;
		private int numChars;

		public Reader() {
			this(System.in);
		}

		public Reader(InputStream is) {
			mIs = is;
		}

		public int read() {
			if (numChars == -1) {
				throw new InputMismatchException();

			}
			if (curChar >= numChars) {
				curChar = 0;
				try {
					numChars = mIs.read(buf);
				} catch (IOException e) {
					throw new InputMismatchException();
				}
				if (numChars <= 0) {
					return -1;
				}
			}
			return buf[curChar++];
		}

		public String nextLine() {
			int c = read();
			while (isSpaceChar(c)) {
				c = read();
			}
			StringBuilder res = new StringBuilder();
			do {
				res.appendCodePoint(c);
				c = read();
			} while (!isEndOfLine(c));
			return res.toString();
		}

		public String next() {
			int c = read();
			while (isSpaceChar(c)) {
				c = read();
			}
			StringBuilder res = new StringBuilder();
			do {
				res.appendCodePoint(c);
				c = read();
			} while (!isSpaceChar(c));
			return res.toString();
		}

		double nextDouble() {
			return Double.parseDouble(next());
		}

		public long nextLong() {
			int c = read();
			while (isSpaceChar(c)) {
				c = read();
			}
			int sgn = 1;
			if (c == '-') {
				sgn = -1;
				c = read();
			}
			long res = 0;
			do {
				if (c < '0' || c > '9') {
					throw new InputMismatchException();
				}
				res *= 10;
				res += c - '0';
				c = read();
			} while (!isSpaceChar(c));
			return res * sgn;
		}

		public int nextInt() {
			int c = read();
			while (isSpaceChar(c)) {
				c = read();
			}
			int sgn = 1;
			if (c == '-') {
				sgn = -1;
				c = read();
			}
			int res = 0;
			do {
				if (c < '0' || c > '9') {
					throw new InputMismatchException();
				}
				res *= 10;
				res += c - '0';
				c = read();
			} while (!isSpaceChar(c));
			return res * sgn;
		}

		public boolean isSpaceChar(int c) {
			return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
		}

		public boolean isEndOfLine(int c) {
			return c == '\n' || c == '\r' || c == -1;
		}
	}

	static Reader r = new Reader();

	static void solve1() {

		int n = r.nextInt();
		int m = r.nextInt();

		int arr[] = new int[m];
		for (int i = 0; i < m; i++) {
			arr[i] = r.nextInt();
		}

		long ans = 0;
		int prev = 1;
		for (int i = 0; i < m; i++) {
			if (arr[i] >= prev)
				ans += (arr[i] - prev);
			else
				ans += (arr[i] - prev + n);
			prev = arr[i];
		}

		System.out.println(ans);
	}

	static void solve2() {

		int n = r.nextInt();
		int m = r.nextInt();
		int k = r.nextInt();

		int arr[] = new int[m + 2];
		for (int i = 1; i <= m + 1; i++) {
			arr[i] = r.nextInt();
		}

		int num = arr[m + 1], ans = 0;
		for (int i = 1; i <= m; i++) {
			int cnt = 0;
			BigInteger l = BigInteger.valueOf(arr[i]);
			BigInteger b = BigInteger.valueOf(num);
			for (int j = 0; j < n; j++) {
				if ((l.testBit(j) && !b.testBit(j)) || (!l.testBit(j) && b.testBit(j))) {
					cnt++;
				}
			}
			if (cnt <= k)
				ans++;
		}
		System.out.println(ans);

	}

	private static void solve3() {

		int n = r.nextInt();
		int l = r.nextInt();

		double arr[] = new double[n];
		for (int i = 0; i < n; i++) {
			arr[i] = r.nextInt();
		}

		Arrays.sort(arr);
		double start = arr[0] - 0;
		double end = l - arr[n - 1];

		double max = Double.MIN_VALUE;
		for (int i = 1; i < n; i++) {
			if ((arr[i] - arr[i - 1]) > max) {
				max = (arr[i] - arr[i - 1]);
			}
		}

		max /= 2;
		double max2 = Math.max(start, end);

		double ans = Math.max(max, max2);
		System.out.printf("%.10f", ans);

	}

	private static void solve4() {

		int n = r.nextInt();
		int arr[] = new int[n];

		for (int i = 0; i < n; i++) {
			arr[i] = r.nextInt();
		}

		int decCnt = 0;
		int start = -1, end = (n - 1);

		boolean flag = false;

		for (int i = 0; i < n - 1; i++) {
			if (arr[i] > arr[i + 1]) {
				if (!flag)
					decCnt++;
				if (start == -1) {
					start = i;
					flag = true;
				}
			} else if (flag && arr[i] < arr[i + 1]) {
				end = i;
				flag = false;
			}
		}

//		System.out.println(start + " " + end);
//		System.out.println(decCnt);

		if (decCnt >= 2) {
			System.out.println("no");
		} else {

			if (decCnt == 0) {
				System.out.println("yes");
				System.out.println(1 + " " + 1);
			} else {
				if (start == 0) {

					if (end == n - 1) {
						System.out.println("yes");
						System.out.println((start + 1) + " " + (end + 1));
					} else {
						if (arr[start] < arr[end + 1]) {
							System.out.println("yes");
							System.out.println((start + 1) + " " + (end + 1));
						} else {
							System.out.println("no");
						}
					}

				} else if (end == n - 1) {

					if (arr[start - 1] < arr[end]) {
						System.out.println("yes");
						System.out.println((start + 1) + " " + (end + 1));
					} else {
						System.out.println("no");
					}

				} else {

					if (arr[start] < arr[end + 1] && arr[end] > arr[start - 1]) {
						System.out.println("yes");
						System.out.println((start + 1) + " " + (end + 1));
					} else {
						System.out.println("no");
					}

				}
			}

		}

	}

	private static void solve5() {

		int n = r.nextInt();
		int m = r.nextInt();

		HashMap<String, String> map = new HashMap<String, String>();
		for (int i = 0; i < m; i++) {
			String s1 = r.next();
			String s2 = r.next();
			map.put(s1, s2);
			map.put(s2, s1);
		}

		for (int i = 0; i < n; i++) {
			String s = r.next();
			String s2 = map.get(s);

			if (s2.length() < s.length()) {
				System.out.print(s2 + " ");
			} else {
				System.out.print(s + " ");
			}
		}

	}

	private static boolean primeCheck(int num) {

		boolean flag = true;
		int cnt = 0;
		for (int i = 2; i * i <= num; i++) {
			if (num % i == 0) {
				flag = false;
			}
		}

		if (num == 1) {
			flag = false;
		}

		return flag;
	}

	private static void solve6() {

		int n = r.nextInt();
		long arr[] = new long[n];

		for (int i = 0; i < n; i++) {
			arr[i] = r.nextLong();
		}

		for (int i = 0; i < n; i++) {
			double root = Math.sqrt(arr[i]);
			int root1 = (int) Math.sqrt(arr[i]);

			if (root == root1 && primeCheck(root1)) {
				System.out.println("YES");
			} else {
				System.out.println("NO");
			}
		}

	}

	private static void solve7() {

		char[] s = r.next().toCharArray();

		int j = -1;
		int x = s[s.length - 1] - '0';

		for (int i = 0; i < s.length - 1; i++) {
			int y = s[i] - '0';

			if (y % 2 == 0) {
				j = i;
				if (y < x)
					break;
			}

		}

		if (j == -1)
			System.out.println(-1);
		else {
			char temp = s[j];
			s[j] = s[s.length - 1];
			s[s.length - 1] = temp;
			System.out.println(s);
		}

	}

	private static void solve8() {

		String s = r.next();
		char str[] = s.toCharArray();

		int k = r.nextInt();

		int arr[] = new int[26];
		int max = Integer.MIN_VALUE;

		for (int i = 0; i < 26; i++) {
			arr[i] = r.nextInt();
			if (arr[i] > max)
				max = arr[i];
		}

		long ans = 0;
		for (int i = 0; i < str.length; i++) {
			ans += ((i + 1) * arr[str[i] - 'a']);
		}

		for (int i = str.length; i < str.length + k; i++) {
			ans += ((i + 1) * max);
		}

		System.out.println(ans);

	}

	private static void solve9() {

		int m = r.nextInt();
		int s = r.nextInt();

		if (!(s >= 0 && s <= m * 9)) {
			System.out.println(-1 + " " + -1);
		} else {
			if (s == 0) {
				if (m == 1) {
					System.out.println(0 + " " + 0);
				} else {
					System.out.println(-1 + " " + -1);
				}
			} else {
				StringBuilder min = new StringBuilder();
				StringBuilder max = new StringBuilder();

				int temp = s, temp2 = s - 1;

				for (int i = 1; i <= m - 1; i++) {
					if (temp2 >= 9) {
						min.append(9);
						temp2 -= 9;
					} else {
						min.append(temp2);
						temp2 = 0;
					}
				}
				min.append(temp2 + 1);
				min = min.reverse();

				for (int i = 1; i <= m; i++) {
					if (temp >= 9) {
						max.append(9);
						temp -= 9;
					} else {
						max.append(temp);
						temp = 0;
					}
				}

				System.out.println(min + " " + max);
			}
		}

	}

	private static void solve10() {

		int n = r.nextInt();
		int arr[] = new int[n];

		for (int i = 0; i < n; i++) {
			arr[i] = r.nextInt();
		}

		System.out.println(countways(arr, n));

	}

	private static long countways(int a[], int n) {
		long cnt[] = new long[n];
		long s = 0;

		for (int i = 0; i < n; i++) {
			s += a[i];
		}

		if (s % 3 != 0)
			return 0;

		s /= 3;

		long ss = 0;

		for (int i = n - 1; i >= 0; i--) {
			ss += a[i];
			if (ss == s)
				cnt[i] = 1;
		}

		for (int i = n - 2; i >= 0; i--)
			cnt[i] += cnt[i + 1];

		long ans = 0;
		ss = 0;

		for (int i = 0; i + 2 < n; i++) {
			ss += a[i];
			if (ss == s)
				ans += cnt[i + 2];
		}
		return ans;
	}

	private static void solve11() {

		int n = r.nextInt();
		int m = r.nextInt();

		StringBuilder ans = new StringBuilder();

		int x = Math.min(m - n, n);
		if (n >= x) {
			for (int i = 1; i <= x; i++) {
				ans.append("011");
			}
			n -= x;
			m -= 2 * x;
			for (int i = 1; i <= n && n > 0 && m > 0; i++) {
				ans.append("01");
				m--;
				n--;
			}
			if (m <= 2) {
				for (int i = 1; i <= m; i++) {
					ans.append(1);
				}
				System.out.println(ans);
			} else
				System.out.println(-1);
		} else {
			System.out.println(-1);
		}

	}

	private static void solve12() {

		int rad = r.nextInt();
		int x = r.nextInt();
		int y = r.nextInt();
		int x_ = r.nextInt();
		int y_ = r.nextInt();

		int cDiff = (int) Math.hypot((x_ - x), (y_ - y));

		int ans = Math.max((int) Math.ceil(cDiff / rad) - 1, 0);
		System.out.println(ans);

	}

	public static void main(String[] args) {

		// xenia and ringroad
//		solve1();

		// fedor and new Game
//		solve2();

		// vanya and lanterns
//		solve3();

		// sort the array
//		solve4();

		// lecture
//		solve5();

		// T-primes
//		solve6();

		// anton and currency
//		solve7();

		// DZY loves strings
//		solve8();

		// given length and sum of digits
//		solve9();

		// Number Of Ways
//		solve10();

		// Team
//		solve11();

		// amr and Pins
		solve12();

	}

}

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

public class Main {

    public void solve() throws IOException {
        long R=nextLong(),
            x0=nextLong(), y0=nextLong(),
            x1=nextLong(), y1=nextLong();
        R=R*R*4;
        long dist=((long)x1-x0)*(x1-x0)+(y1-y0)*(y1-y0);
        long l=0, r=1000000;
        while (l<r) {
            long mid=l+(r-l)/2;
            long step=mid*mid*R;
            if (step>=dist) r=mid;
            else l=mid+1;
        }
        out.println(r);
    }

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

    final String fileIn = "test.in";
    final String fileOut = "output.txt";
    BufferedReader in;
    PrintWriter out;
    StringTokenizer st = new StringTokenizer("");

    private void run() throws IOException {
//      if (new File(fileIn).exists())
//          in = new BufferedReader(new FileReader(fileIn));
//      else {
            in = new BufferedReader(new InputStreamReader(System.in)); // стандартный ввод
//      }
//      if (new File(fileOut).exists()) {
//          out = new PrintWriter(new FileWriter(fileOut));
//      } else {
            out = new PrintWriter(System.out); // стандартный вывод
//      }
        solve();
        in.close();
        out.close();
    }

    String nextToken() throws IOException {
        while (!st.hasMoreTokens())
            st = new StringTokenizer(in.readLine());
        return st.nextToken();
    }

    int gcd(int a, int b) {
        return (b == 0 ? a : gcd(b, a % b));
    }

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

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

    double nextDouble() throws IOException {
        return Double.parseDouble(nextToken());
    }

    String nextLine() throws IOException {
        st = new StringTokenizer("");
        return in.readLine();
    }

    boolean EOF() throws IOException {
        while (!st.hasMoreTokens()) {
            String s = in.readLine();
            if (s == null)
                return true;
            st = new StringTokenizer(s);
        }
        return false;
    }
}

import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        int r=s.nextInt(), x1=s.nextInt(), y1=s.nextInt(), x2=s.nextInt(), y2=s.nextInt();
        int time=0;
        s.close();
        int distance=(int) Math.sqrt(Math.pow(Math.abs(x1-x2),2)+Math.pow(Math.abs(y1-y2),2));

        double c1 = distance/r;
        //System.out.println(Math.floor(c1));
        if(Math.floor(c1)==c1){
            while(distance>1){
                distance=distance-r;
                time++;
            }
        }
        System.out.println(time);
    }
}

import java.util.Scanner;

public class Main {

	public static void main(String[] args) {

		Scanner scn = new Scanner(System.in);

		int r = scn.nextInt();
		int x = scn.nextInt();
		int y = scn.nextInt();
		int x1 = scn.nextInt();
		int y1 = scn.nextInt();

		double length = Math.sqrt((x - x1) * (x - x1) + (y - y1) * (y - y1));

		r *= 2;

		length /= r;

		int ans = (int) (length);

		if (ans == length) {
			ans--;
		}

		System.out.println(ans + 1);

	}

}

import java.util.Scanner;

public class B {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int r = sc.nextInt();
        int x = sc.nextInt();
        int y = sc.nextInt();
        int x1 = sc.nextInt();
        int y1 = sc.nextInt();
        double d = Math.sqrt((x1 - x)*(x1 - x) + (y1 - y)*(y1 - y));
        r *= 2;
        int d1 = (int)d;
        int k = d1 / r;
        double c = d - k*r;
        double eps = 0.0001;
        System.out.println(k + (c > eps ? 1 : 0));
    }

}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.*;

public class Main
{
    public static double getDistance(double x, double y, double x1, double y1)
    {
        double xD = x1 - x;
        double yD = y1 - y;
        return Math.sqrt( xD * xD + yD * yD );
    }
    public static void main(String args[])
    {
        MyScanner scanner = new MyScanner();
        int turns = 0;
        double r = scanner.nextInt(), x = scanner.nextInt(), y = scanner.nextInt() , x1 = scanner.nextInt(), y1 = scanner.nextInt();
        double distance = getDistance(x, y, x1, y1 );
        while ( distance >= 2 * r )
        {
            distance -= (2 * r);
            turns++;
        }
        if( distance > r )
        {
            turns++;
        }
        turns++;
        System.out.println(turns);
    }
}

class MyScanner {
    BufferedReader br;
    StringTokenizer st;

    public MyScanner() {
        br = new BufferedReader(new InputStreamReader(System.in));
    }

    public int mod(long x) {
        // TODO Auto-generated method stub
        return (int) x % 1000000007;
    }

    public int mod(int x) {
        return x % 1000000007;
    }

    boolean hasNext() {
        if (st.hasMoreElements())
            return true;
        try {
            st = new StringTokenizer(br.readLine());
        } catch (IOException e) {
            e.printStackTrace();
        }
        return st.hasMoreTokens();
    }

    String next() {
        while (st == null || !st.hasMoreElements()) {
            try {
                st = new StringTokenizer(br.readLine());
            } catch (Exception e) {
                e.printStackTrace();
            }
        }
        return st.nextToken();
    }

    int nextInt() {
        return Integer.parseInt(next());
    }

    double nextDouble() {
        return Double.parseDouble(next());
    }

    String nextLine() {
        String str = "";
        try {
            str = br.readLine();
        } catch (IOException e) {
            e.printStackTrace();
        }
        return str;
    }

    public long nextLong() {
        return Long.parseLong(next());
    }
}

import static java.lang.Math.pow;
import java.util.Scanner;

public class amrpin {
    public static void main (String[] args)
    {
        Scanner input = new Scanner(System.in);
        int  x ,y ,x1 , y1 ;
        int r ;
        double d=0.0;
        r=input.nextInt();
        x=input.nextInt();
        y=input.nextInt();
        x1=input.nextInt();
        y1=input.nextInt();
//        double z = pow((pow((x1-x),2)+pow((y-y1),2)),0.5);
        if(x==x1&&y==y1)
           System.out.println(0);

        else
        {
        if(x==x1)
            d=y1-y ;
        else
        if(y==y1)
            d=x1-x;
        else
        {
        double a=Math.pow((x1-x),2);
        double b=Math.pow((y1-y),2);
        double c=a+b;
        d=Math.pow(c,0.5);
        }
        int z=0;
        while(d>0)
        {
            d-=2*r;
            z++;
        }
        System.out.println(z);

        }

    }

}

import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.FileReader;
import java.io.FileWriter;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.math.BigInteger;
import java.util.StringTokenizer;

public class B {

    public static void main(String[] args) throws IOException {
        br = new BufferedReader( new InputStreamReader(System.in) );
        out = new PrintWriter(System.out);
        st = new StringTokenizer("");
        sb = new StringBuilder();

        double r = nxtDbl();
        double x1 = nxtDbl();
        double y1 = nxtDbl();
        double x2 = nxtDbl();
        double y2 = nxtDbl();
        double x = x1-x2;
        double dist = Math.sqrt( Math.pow(x1-x2, 2) + Math.pow(y1-y2, 2) );
        //(int) ((dist / r) - 1);
        int res = 0;
        double div = dist/r;
        if( div < r ){
            res++;
        }
        res +=  (int) ((dist / r) - 1);

        if( dist == 0){
            res = 0;
        }
        System.out.println( res );

    }//end main.

    static BufferedReader br;
    static StringTokenizer st;
    static StringBuilder sb;
    static PrintWriter out;
    static FileReader fr;
    static FileWriter fw;
    static BufferedWriter bw;

    static String nxtTok() throws IOException {
        while (!st.hasMoreTokens()) {
            String s = br.readLine();
            if (s == null)
                return null;
            st = new StringTokenizer(s.trim());
        }
        return st.nextToken();
    }

    static int nxtInt() throws IOException {
        return Integer.parseInt(nxtTok());
    }

    static long nxtLng() throws IOException {
        return Long.parseLong(nxtTok());
    }

    static double nxtDbl() throws IOException {
        return Double.parseDouble(nxtTok());
    }

    static int[] nxtIntArr(int n) throws IOException {
        int[] a = new int[n];
        for (int i = 0; i < n; i++)
            a[i] = nxtInt();
        return a;
    }

    static long[] nxtLngArr(int n) throws IOException {
        long[] a = new long[n];
        for (int i = 0; i < n; i++)
            a[i] = nxtLng();
        return a;
    }

    static char[] nxtCharArr() throws IOException {
        return nxtTok().toCharArray();
    }

}//end class.

/* package whatever; // don't place package name! */

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

/* Name of the class has to be "Main" only if the class is public. */
public final class Ideone
{
	public static void main (String[] args) throws java.lang.Exception
	{
		// your code goes here
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String s1[] = br.readLine().split(" ");
		double r = Integer.parseInt(s1[0]);
		double x = Integer.parseInt(s1[1]);
		double y = Integer.parseInt(s1[2]);
		double x1 = Integer.parseInt(s1[3]);
		double y1 = Integer.parseInt(s1[4]);
		double z = 0.0;
		if(x1 < 0 && y1 < 0 && x>0 && y >0){
			x1 = x1 * -1;
			y1 = y1 * -1;
		}
		if ((x1 - x) < 0)
			z = z + (-1)*(x1 - x);
		else
			z = z + (x1 - x);
		if((y1-y)< 0)
			z = z + (-1)*(y1 - y);
		else
			z = z + (y1 - y);
		z = z / ( 2* r);
		z = Math.ceil(z);
		//System.out.println(z);
		int q = (int)(z);
		System.out.println(q);

	}
}

import java.util.*;
import java.io.*;
public class spoj
{
    public static void main(String[] args)
    {
        Scanner sc=new Scanner(System.in);
        int r=sc.nextInt();
       float x1=sc.nextFloat();
       float y1=sc.nextFloat();
       float x2=sc.nextFloat();
       float y2=sc.nextFloat();
       float dist=(float)Math.sqrt(Math.pow(x1-x2,2)+Math.pow(y1-y2,2));
       System.out.println(Math.ceil(dist/2*r));

    }
}

import java.util.*;

public class ACB {
	public static void main(String args[]) throws Exception {
		//System.out.println("Hiiiii");
		Scanner scn = new Scanner(System.in);
		int r = scn.nextInt();
		int x = scn.nextInt();
		int y = scn.nextInt();
		int x1 = scn.nextInt();
		int y1 = scn.nextInt();
		if (x == x1 && y == y1) {
			System.out.println(0);
		} else {
			int d = (int) Math.pow((Math.pow(x - x1, 2) + Math.pow(y - y1, 2)), 0.5);
			System.out.println(d - (2 * r) + 1);
		}

	}
}

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

public class Solution {
    public static void main(String[] args) throws Exception{
        Scanner sc = new Scanner(System.in);
        PrintWriter pw = new PrintWriter(System.out);
        int r = sc.nextInt(), x = sc.nextInt(), y = sc.nextInt(), x1 = sc.nextInt(), y1 = sc.nextInt();
        if (x < 0) {
            x1 -= x;
            x = 0;
        }
        if (x1 < 0) {
            x -= x1;
            x1 = 0;
        }
        if (y < 0) {
            y1 -= y;
            y = 0;
        }
        if (y1 < 0) {
            y -= y1;
            y1 = 0;
        }
        int rasst = (int) Math.floor(Math.sqrt(Math.pow(x-x1, 2) + Math.pow(y-y1, 2)));
        int k = 0;
        if (x == x1 && y == y1) {
            rasst = 0;
        } else if (rasst<=r) {
            k = 1;
            rasst = 0;
        } else {
            rasst-=r;
            k++;
            while (rasst > 0) {
                rasst = Math.max(0, rasst-2*r);
                k++;
            }
        }
        pw.println(k);
        pw.close();
    }
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class AmrAndPins {

	public static void main(String[] args) {
		MyScanner scan = new MyScanner();
		int r = scan.nextInt();
		int x = scan.nextInt();
		int y = scan.nextInt();
		int x2 = scan.nextInt();
		int y2 = scan.nextInt();

		double distance = Math.sqrt(Math.abs((x2-x)*(x2-x))+Math.abs((y2-y)*(y2-y)));
		System.out.println((int)Math.ceil(distance/(r*2)));
	}

	//-----------MyScanner class for faster input----------
	   public static class MyScanner {
	      BufferedReader br;
	      StringTokenizer st;

	      public MyScanner() {
	         br = new BufferedReader(new InputStreamReader(System.in));
	      }

	      String next() {
	          while (st == null || !st.hasMoreElements()) {
	              try {
	                  st = new StringTokenizer(br.readLine());
	              } catch (IOException e) {
	                  e.printStackTrace();
	              }
	          }
	          return st.nextToken();
	      }

	      int nextInt() {
	          return Integer.parseInt(next());
	      }

	      long nextLong() {
	          return Long.parseLong(next());
	      }

	      double nextDouble() {
	          return Double.parseDouble(next());
	      }

	      String nextLine(){
	          String str = "";
		  try {
		     str = br.readLine();
		  } catch (IOException e) {
		     e.printStackTrace();
		  }
		  return str;
	      }

	   }
	   //--------------------------------------------------------
}

import java.util.Scanner;
public class Stick {
	public static void main(String args[]) {
		int r,x1,y1,x2,y2;
		Scanner input = new Scanner(System.in);
		r = input.nextInt();
		x1 = input.nextInt();
		y1 = input.nextInt();
		x2 = input.nextInt();
		y2 = input.nextInt();
		double dist = Math.sqrt((x2 - x1) * (x2 - x1) + (y2 - y1) * (y2 - y1));
		System.out.print((int)Math.ceil(dist / (2.0 * r)));
	}
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class B507 {
    public static BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
    public static StringTokenizer tok;

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

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

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

        return tok.nextToken();
    }

    public static void main(String[] args) throws Exception {
        long r = nextInt();
        long x1 = nextInt();
        long y1 = nextInt();
        long x2 = nextInt();
        long y2 = nextInt();

        double d = Math.sqrt((x2 - x1) * (x2 - x1) + (y2 - y1) * (y2 - y1)) / r;

        int k = 0;
        while (d - r > 1e-10) {
            d -= 2 * r;
            k++;
        }
        System.out.println((d < 1e-10 ? 0 : 1) + k);
    }
}

import java.util.Scanner;
import java.util.StringTokenizer;

public class alphatest {

	public static void main(String[] args){

	Scanner sc=new Scanner(System.in);

int r=sc.nextInt();
int x0=sc.nextInt();
int y0=sc.nextInt();

int x1=sc.nextInt();
int y1=sc.nextInt();

double dist=Math.sqrt((x1-x0)*(x1-x0)+(y1-y0)*(y1-y0));
System.out.println((int)Math.ceil(dist/2*r));

}
}

import java.util.*;
import java.io.*;
public class Solution {
	static class FastReader
    {
        BufferedReader br;
        StringTokenizer st;

        public FastReader()
        {
            br = new BufferedReader(new
                     InputStreamReader(System.in));
        }

        String next()
        {
            while (st == null || !st.hasMoreElements())
            {
                try
                {
                    st = new StringTokenizer(br.readLine());
                }
                catch (IOException  e)
                {
                    e.printStackTrace();
                }
            }
            return st.nextToken();
        }

        int nextInt()
        {
            return Integer.parseInt(next());
        }

        long nextLong()
        {
            return Long.parseLong(next());
        }

        double nextDouble()
        {
            return Double.parseDouble(next());
        }

        String nextLine()
        {
            String str = "";
            try
            {
                str = br.readLine();
            }
            catch (IOException e)
            {
                e.printStackTrace();
            }
            return str;
        }
    }
  public static void main(String [] args) {
	FastReader ip=new FastReader();
	int r=ip.nextInt();
	int x1=ip.nextInt();
	int y1=ip.nextInt();
	int x2=ip.nextInt();
	int y2=ip.nextInt();
	int a=(x2-x1)*(x2-x1);
	int b=(y2-y1)*(y2-y1);
	double v=Math.sqrt(a+b);
    int ans=(int)Math.ceil(v/(2*r));
    System.out.println(ans);

  }
}

import java.awt.*;
import java.awt.geom.Area;
import java.io.*;
import java.lang.reflect.Array;
import java.math.*;
import java.sql.SQLException;
import java.util.*;
import java.util.Map.Entry;

import javax.management.RuntimeErrorException;

import static java.lang.Math.*;

public class Solution implements Runnable {
        final boolean ONLINE_JUDGE = System.getProperty("ONLINE_JUDGE") != null;
        BufferedReader in;
        PrintWriter out;
        StringTokenizer tok = new StringTokenizer("");
        String delim = " ";

        String readString() throws IOException {
        	try {
	    		while(!tok.hasMoreTokens()) {
	    			tok = new StringTokenizer(in.readLine());
		        }
		        return tok.nextToken(delim);
	    	}
        	catch (Exception e){
        		return null;
	    	}
        }

        int readInt() throws IOException{
            return Integer.parseInt(readString());
        }
        long readLong() throws IOException{
            return Long.parseLong(readString());
        }
        double readDouble() throws IOException{
            return Double.parseDouble(readString());
        }
        Point readPoint() throws IOException {
        	return new Point(readInt(), readInt());
        }
        char readChar() throws IOException{
        	int x = 0;
        	while ((x = in.read()) == '\n' || x == '\r' || x == ' '){ }
        	return (char)x;
        }
//----------------------------------
        public class Three {
            public int a, b, c;
            public Three(){}
            public Three(int a, int b, int c){this.a = a;this.b=b;this.c=c;}
            public String toString(){
                return a + ":" + b + ":" + c;
            }
        }
//----------------------------------------

        void solve() throws IOException {
        	int r = readInt();
        	int x = readInt();
        	int y = readInt();
        	int xx = readInt();
        	int yy = readInt();

        	long length = (xx - x)*1l*(xx - x) + (yy - y)*1l*(yy - y);

        	if (length == 0){
        		out.print(0);
        		return;
        	}

        	long rr = r*1l*r;

        	long del = (long)Math.sqrt(length/rr);
        	if (length % rr != 0){
        		del++;
        	}

        	out.print(max(0, del));
        }

//----------------------------------------
        public static void main(String[] args){
            new Thread(null, new Solution(), "", 256 * (1L << 20)).start();
        }

        public void run(){
                try{
                        timeBegin = System.currentTimeMillis();

                        try{
                            if (ONLINE_JUDGE){
                                in = new BufferedReader(new InputStreamReader(System.in));
                                out = new PrintWriter(System.out);
                            }
                            else {
                            	in = new BufferedReader(new FileReader("input.txt"));
                            	out = new PrintWriter("output.txt");
                            }
                        }catch(Throwable e){
                            in = new BufferedReader(new InputStreamReader(System.in));
                            out = new PrintWriter(System.out);
                        }

                        solve();
                        out.close();

                        timeEnd = System.currentTimeMillis();
                        System.err.println("Time = " + (timeEnd - timeBegin));
                }catch (Exception e){
                        e.printStackTrace(System.err);
                        System.exit(-1);
                }
        }

        long timeBegin, timeEnd;
}

import java.util.Scanner;

public class Solution{

    public static double dist(int x, int y , int a , int b){
        double t = ((x - a)*(x - a)) + ((y - b)*(y - b));
        return Math.sqrt(t);

    }

    public static void main(String args[]){
        Scanner scn = new Scanner(System.in);

        int r = scn.nextInt();
        int x = scn.nextInt();
        int y = scn.nextInt();

        int a = scn.nextInt();
        int b = scn.nextInt();

        if(x == a && y == b){
            System.out.println("0");
            return;
        }

        double ans = Math.ceil(dist(x , y , a , b)/(2*r));
        System.out.println((int)ans);
    }
}

import java.util.Arrays;

import java.util.Scanner;
import java.util.TreeMap;
import java.util.TreeSet;
import java.io.IOException;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.Comparator;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Hashtable;
import java.util.InputMismatchException;
import java.util.LinkedList;
import java.util.Map;
import java.util.PriorityQueue;
public class R287_2 {
    public static void main(String args[]){
        FasterScanner s=new FasterScanner();
        PrintWriter out=new PrintWriter(System.out);
        int r=s.nextInt();
        int x=s.nextInt();
        int y=s.nextInt();
        int x1=s.nextInt();
        int y1=s.nextInt();
        System.out.println((int)Math.abs(Math.sqrt((x-x1)*(x-x1)+(y-y1)*(y-y1))/2*r));
        out.close();
    }

   static class n implements Comparable<n>{
       int id;
       int val;
    @Override
    public int compareTo(n o) {
        return Integer.compare(this.val,o.val);
    }
   }

    public static class FasterScanner {
        private byte[] buf = new byte[1024];
        private int curChar;
        private int numChars;

        public int read() {
            if (numChars == -1)
                throw new InputMismatchException();
            if (curChar >= numChars) {
                curChar = 0;
                try {
                    numChars = System.in.read(buf);
                } catch (IOException e) {
                    throw new InputMismatchException();
                }
                if (numChars <= 0)
                    return -1;
            }
            return buf[curChar++];
        }

        public String nextLine() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            StringBuilder res = new StringBuilder();
            do {
                res.appendCodePoint(c);
                c = read();
            } while (!isEndOfLine(c));
            return res.toString();
        }

        public String nextString() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            StringBuilder res = new StringBuilder();
            do {
                res.appendCodePoint(c);
                c = read();
            } while (!isSpaceChar(c));
            return res.toString();
        }

        public long nextLong() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            long res = 0;
            do {
                if (c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            } while (!isSpaceChar(c));
            return res * sgn;
        }

        public int nextInt() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            int res = 0;
            do {
                if (c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            } while (!isSpaceChar(c));
            return res * sgn;
        }

        public int[] nextIntArray(int n) {
            int[] arr = new int[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }
            return arr;
        }

        public long[] nextLongArray(int n) {
            long[] arr = new long[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextLong();
            }
            return arr;
        }

        private boolean isSpaceChar(int c) {
            return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }

        private boolean isEndOfLine(int c) {
            return c == '\n' || c == '\r' || c == -1;
        }
    }

    public static class disjointSet {

        private int[] parent;  // parent[i] = parent of i
        private byte[] rank;   // rank[i] = rank of subtree rooted at i (never more than 31)
        private int count;     // number of components
        public disjointSet(int N) {
            if (N < 0) throw new IllegalArgumentException();
            count = N;
            parent = new int[N];
            rank = new byte[N];
            for (int i = 0; i < N; i++) {
                parent[i] = i;
                rank[i] = 0;
            }
        }

        public int find(int p) {
            if (p < 0 || p >= parent.length) throw new IndexOutOfBoundsException();
            while (p != parent[p]) {
                parent[p] = parent[parent[p]];    // path compression by halving
                p = parent[p];
            }
            return p;
        }
        public int count() {
            return count;
        }

        public boolean connected(int p, int q) {
            return find(p) == find(q);
        }

        public boolean union(int p, int q) {
            int rootP = find(p);
            int rootQ = find(q);
            if (rootP == rootQ) return false;

            // make root of smaller rank point to root of larger rank
            if      (rank[rootP] < rank[rootQ]) parent[rootP] = rootQ;
            else if (rank[rootP] > rank[rootQ]) parent[rootQ] = rootP;
            else {
                parent[rootQ] = rootP;
                rank[rootP]++;
            }
            count--;
            return true;
        }

    }
}

import java.io.*;
import java.util.*;
import java.nio.charset.StandardCharsets;
// import java.math.BigInteger;

public class B {
    static Writer wr;

    static class State {
        public int u;
        public int v;
        public int d;
        public State(int a, int b, int dd) {
            u = a;
            v = b;
            d = dd;
        }

        public boolean equals(Object obj) {
            if (this == obj)
                return true;
            if (obj == null)
                return false;

            State other = (State)obj;
            if((other.u==u && other.v==v))
            {
                return true;
            }
            return false;
        }

        public int hashCode() {
            final int prime = 31;
            int result = 23;
            result = prime * result + u;
            result = prime * result + v;
            // result = prime * result + w;
            // System.out.print(result + " ");
            return result;
        }
    }

    public static void main(String[] args) throws Exception {
        // long startTime = System.nanoTime();

        // String testString = "";
        // InputStream stream = new ByteArrayInputStream(testString.getBytes(StandardCharsets.UTF_8));
        // Reader in = new Reader(stream);

        Reader in = new Reader();
        BufferedWriter out = new BufferedWriter(new OutputStreamWriter(System.out));

        wr = new Writer();

        /* Precomputation */

        // long elapsedTime = System.nanoTime() - startTime;
        // double seconds = (double)elapsedTime / 1000000000.0;
        // wr.writeRedLn(seconds);

        /* Input */
        int r = in.nextInt();
        int x = in.nextInt();
        int y = in.nextInt();
        int x1 = in.nextInt();
        int y1 = in.nextInt();

        int dx[] = {1*r,-1*r,1*r,-1*r,2*r,-2*r,0,0};
        int dy[] = {1*r,-1*r,-1*r,1*r,0,0,2*r,-2*r};

        Queue<State> q = new LinkedList<>();
        State start = new State(x,y,0);
        q.add(start);

        HashSet<State> visited = new HashSet<>();
        visited.add(start);

        int ans = 0;
        outer:
        while(q.size()>0) {
            State curr = q.poll();
            if((curr.u == x1) && (curr.v == y1)) {
                ans = curr.d;
                break outer;
            }
            // wr.writeRedLn(curr.u + ", " + curr.v + ", d: "  + curr.d);
            if(curr.d==4) break;
            for(int i=0;i<dx.length;i++) {

                State nx = new State(curr.u+dx[i],curr.v+dy[i], curr.d+1);
                // wr.writeBlueLn(nx.u + ", " + nx.v + ", d: "  + nx.d);
                if((nx.u == x1) && (nx.v == y1)) {
                    ans = nx.d;
                    break outer;
                }
                if(!visited.contains(nx)) {
                    q.add(nx);
                    visited.add(nx);
                }
            }
        }

        out.write(ans + "\n");
        out.flush();
    }
}

class Writer {
    public void writeRedLn(Object x) { writeRedLn(x+""); }
    public void writeBlueLn(Object x) { writeBlueLn(x+""); }
    public void writeGreenLn(Object x) { writeGreenLn(x+""); }
    public void writePinkLn(Object x) { writePinkLn(x+""); }
    public void writeRedLn(String x) { System.out.println((char)27 + "[31m" + (char)27 + "[40m" + x + (char)27 + "[0m"); }
    public void writeBlueLn(String x) { System.out.println((char)27 + "[34m" + (char)27 + "[3m" + x + (char)27 + "[0m"); }
    public void writeGreenLn(String x) { System.out.println((char)27 + "[32m" + (char)27 + "[3m" + x + (char)27 + "[0m"); }
    public void writePinkLn(String x) { System.out.println((char)27 + "[30m" + (char)27 + "[45m" + x + (char)27 + "[0m"); }
    public void writeRed(String x) { System.out.print((char)27 + "[31m" + (char)27 + "[40m" + x + (char)27 + "[0m"); }
    public void writeBlue(String x) { System.out.print((char)27 + "[34m" + (char)27 + "[3m" + x + (char)27 + "[0m"); }
    public void writeGreen(String x) { System.out.print((char)27 + "[32m" + (char)27 + "[3m" + x + (char)27 + "[0m"); }
    public void writePink(String x) { System.out.print((char)27 + "[30m" + (char)27 + "[45m" + x + (char)27 + "[0m"); }
}

class Reader {
    public int LINE_LIMIT = -1;
    final private int BUFFER_SIZE = 1 << 16;private DataInputStream din;private byte[] buffer;private int bufferPointer, bytesRead;
    public Reader(){din=new DataInputStream(System.in);buffer=new byte[BUFFER_SIZE];bufferPointer=bytesRead=0;}
    public Reader(InputStream stream){din=new DataInputStream(stream);buffer=new byte[BUFFER_SIZE];bufferPointer=bytesRead=0;}
    public int[] ni_array(int N) throws IOException { int[] ans = new int[N]; for(int i=0;i<N;i++) { ans[i] = nextInt(); } return ans; }
    public String readLineUtil()throws IOException{byte[] buf=new byte[Math.max(400024,LINE_LIMIT)];int cnt=0,c;
        while((c=read())!=-1){if(c=='\n')break;buf[cnt++]=(byte)c;}return new String(buf,0,cnt);}
    public String readLine() throws IOException{ String line = readLineUtil().trim(); while(line.length()==0) line = readLineUtil().trim(); return line; }
    public char nextChar()throws IOException{byte c=read();while(c<=' ')c=read();return (char)c;}
    public int nextInt()throws IOException{int ret=0;byte c=read();while(c<=' ')c=read();boolean neg=(c=='-');
        if(neg)c=read();do{ret=ret*10+c-'0';}while((c=read())>='0'&&c<='9');if(neg)return -ret;return ret;}
    public long nextLong()throws IOException{long ret=0;byte c=read();while(c<=' ')c=read();boolean neg=(c=='-');
        if(neg)c=read();do{ret=ret*10+c-'0';}while((c=read())>='0'&&c<='9');if(neg)return -ret;return ret;}
    public double nextDouble()throws IOException{double ret=0,div=1;byte c=read();while(c<=' ')c=read();boolean neg=(c=='-');if(neg)c = read();do {ret=ret*10+c-'0';}while((c=read())>='0'&&c<='9');
        if(c=='.')while((c=read())>='0'&&c<='9')ret+=(c-'0')/(div*=10);if(neg)return -ret;return ret;}
    private void fillBuffer()throws IOException{bytesRead=din.read(buffer,bufferPointer=0,BUFFER_SIZE);if(bytesRead==-1)buffer[0]=-1;}
    private byte read()throws IOException{if(bufferPointer==bytesRead)fillBuffer();return buffer[bufferPointer++];}
    public void close()throws IOException{if(din==null) return;din.close();}
}

import java.util.Arrays;
import java.util.Comparator;
import java.util.Scanner;

public class Codeforces {
    static class compare {
        int a;
        int b;

        public compare(int a, int b) {
            this.a = a;
            this.b = b;
        }
    }

    // comparator class //
    static Comparator<compare> cmp = new Comparator<compare>() {
        public int compare(compare a, compare b) {
            if (a.a > b.a)
                return 1;
            else if (a.a < b.a)
                return -1;
            else
                return 0;
        }
    };

    static int getDistance(int x1, int y1, int x2, int y2) {
        int distance = (int) Math.sqrt((x1 - x2) * (x1 - x2) + (y1 - y2)
                * (y1 - y2));
        return distance;
    }

    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        int r = s.nextInt();
        int x1 = s.nextInt();
        int y1 = s.nextInt();
        int x2 = s.nextInt();
        int y2 = s.nextInt();

        if (x1 == x2 && y1 == y2) {
            System.out.println(0);
        } else {
            int get = getDistance(x1, y1, x2, y2);
            System.out.println(get);
            int min = get / (r) - 1;

            System.out.println(min);
        }
    }
}

////////////////////---------------------------SHUBHAM CHAUDHARI-------------------------------///////////////////////

import java.util.*;

public class Main {

    static ArrayList<Integer>graph[];
    public static void main(String[] args){
        Scanner in=new Scanner(System.in);
        int r=in.nextInt();
        int x=in.nextInt();
        int y=in.nextInt();
        int xf=in.nextInt();
        int yf=in.nextInt();
        int goalx=Math.abs(x-xf);
        int goaly=Math.abs(y-yf);
        int common=Math.min(goalx,goaly);
        int res=common/r;
        goalx-=common;
        goaly-=common;
        res=res+goalx/(2*r)+goaly/(2*r);
        System.out.println(res);
    }

}

import java.util.*;
import java.lang.*;

public class Main
{
	public static void main(String[]args)
	{
		Scanner sc = new Scanner(System.in);
        int r=sc.nextInt();
        int x=sc.nextInt();
        int y=sc.nextInt();
        int x1=sc.nextInt();
        int y1=sc.nextInt();
        double d;
        d=Math.sqrt((x-x1)*(x-x1)+(y-y1)*(y-y1));
        //System.out.println(d);
        //System.out.println(d/r);
        System.out.println((int)Math.ceil(d/r/2));

	}
}

//package intro_basic;

import java.util.Scanner;

public class geometry_circle {
	public static void main(String[] args)
	{
		Scanner sc=new Scanner(System.in);
		long r,x1,y1,x2,y2;
		r=sc.nextInt();
		x1=sc.nextInt();
		y1=sc.nextInt();
		x2=sc.nextInt();
		y2=sc.nextInt();

		long ans=0,mod=0;
		/*
		ans+=Math.abs((x2-x1))/(2*r);
		mod+=Math.abs((x2-x1))%(2*r);
		ans+=Math.abs((y2-y1))/(2*r);
		mod+=Math.abs((y2-y1))%(2*r);
		if(mod!=0)
		{
			ans+=1;
		}
		*/
		long y=Math.abs(y2-y1);
		long x=Math.abs(x2-x1);
		double dist=Math.sqrt(y*y+x*x);
		ans=(long)dist/(2*r);
		double dist2=(long)dist;
		if(dist!=dist2 && dist2%(2*r)!=0)
		{ans++;}
		System.out.println(ans);
	}
}

import java.awt.*;
import java.awt.geom.Area;
import java.io.*;
import java.lang.reflect.Array;
import java.math.*;
import java.sql.SQLException;
import java.util.*;
import java.util.Map.Entry;

import javax.management.RuntimeErrorException;

import static java.lang.Math.*;

public class Solution implements Runnable {
        final boolean ONLINE_JUDGE = System.getProperty("ONLINE_JUDGE") != null;
        BufferedReader in;
        PrintWriter out;
        StringTokenizer tok = new StringTokenizer("");
        String delim = " ";

        String readString() throws IOException {
        	try {
	    		while(!tok.hasMoreTokens()) {
	    			tok = new StringTokenizer(in.readLine());
		        }
		        return tok.nextToken(delim);
	    	}
        	catch (Exception e){
        		return null;
	    	}
        }

        int readInt() throws IOException{
            return Integer.parseInt(readString());
        }
        long readLong() throws IOException{
            return Long.parseLong(readString());
        }
        double readDouble() throws IOException{
            return Double.parseDouble(readString());
        }
        Point readPoint() throws IOException {
        	return new Point(readInt(), readInt());
        }
        char readChar() throws IOException{
        	int x = 0;
        	while ((x = in.read()) == '\n' || x == '\r' || x == ' '){ }
        	return (char)x;
        }
//----------------------------------
        public class Three {
            public int a, b, c;
            public Three(){}
            public Three(int a, int b, int c){this.a = a;this.b=b;this.c=c;}
            public String toString(){
                return a + ":" + b + ":" + c;
            }
        }
//----------------------------------------

        void solve() throws IOException {
        	int r = readInt();
        	int x = readInt();
        	int y = readInt();
        	int xx = readInt();
        	int yy = readInt();

        	long length = (long)(xx - x)*(xx - x) + (long)(yy - y)*(yy - y);

        	long rr = (long)4*r*r;

        	long del = (long)Math.sqrt((double)length/rr);
        	if (length % rr != 0){
        		del++;
        	}

        	out.print(del);
        }

//----------------------------------------
        public static void main(String[] args){
            new Thread(null, new Solution(), "", 256 * (1L << 20)).start();
        }

        public void run(){
                try{
                        timeBegin = System.currentTimeMillis();

                        try{
                            if (ONLINE_JUDGE){
                                in = new BufferedReader(new InputStreamReader(System.in));
                                out = new PrintWriter(System.out);
                            }
                            else {
                            	in = new BufferedReader(new FileReader("input.txt"));
                            	out = new PrintWriter("output.txt");
                            }
                        }catch(Throwable e){
                            in = new BufferedReader(new InputStreamReader(System.in));
                            out = new PrintWriter(System.out);
                        }

                        solve();
                        out.close();

                        timeEnd = System.currentTimeMillis();
                        System.err.println("Time = " + (timeEnd - timeBegin));
                }catch (Exception e){
                        e.printStackTrace(System.err);
                        System.exit(-1);
                }
        }

        long timeBegin, timeEnd;
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

/**
 * Created by brajesh.k on 15/09/15.
 */
public class Problem507B {
    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String[] line = br.readLine().split(" ");
        int x = Integer.parseInt(line[1]) - Integer.parseInt(line[3]);
        int y = Integer.parseInt(line[2]) - Integer.parseInt(line[4]);
        double dis = Math.sqrt(x * x + y * y);
        int dia = Integer.parseInt(line[0]) * 2;
        System.out.println((int)(dis / dia) + (dis % dia == 0 ? 0 : 1));
    }
}

import java.io.InputStreamReader;
import java.io.IOException;
import java.io.BufferedReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.util.StringTokenizer;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 */
public class Main {
	public static void main(String[] args) {
		InputStream inputStream = System.in;
		OutputStream outputStream = System.out;
		InputReader in = new InputReader(inputStream);
		PrintWriter out = new PrintWriter(outputStream);
		TaskB solver = new TaskB();
		solver.solve(1, in, out);
		out.close();
	}
}

class TaskB {
    public void solve(int testNumber, InputReader in, PrintWriter out) {
        long r = in.nextInt();
        long x = in.nextInt();
        long y = in.nextInt();
        long x1 = in.nextInt();
        long y1 = in.nextInt();

        long od = (x1 - x) * (x1 - x) + (y1 - y) * (y1 - y);
        boolean within = false;
        if (od <= 4L*r * r) {
            within = true;
        }

        double ods = Math.sqrt((double) od);
        long odl = (long)ods;
        boolean equal = false;
        if (odl*odl == od){
            equal = true;
        }
        double ans = (ods/(2*r));
        long a = (long) ans;
        if (!equal){
            a++;
        }
        if (within) {
            if (x1 == x && y1 == y) {
                out.println(0);
            } else {
                out.println(1);
            }
            return;
        }
        out.println(a);
    }
}

class InputReader {
    public BufferedReader reader;
    public StringTokenizer tokenizer;

    public InputReader(InputStream stream) {
        reader = new BufferedReader(new InputStreamReader(stream), 32768);
        tokenizer = null;
    }

    public String next() {
        while (tokenizer == null || !tokenizer.hasMoreTokens()) {
            try {
                tokenizer = new StringTokenizer(reader.readLine());
            } catch (IOException e) {
                throw new RuntimeException(e);
            }
        }
        return tokenizer.nextToken();
    }

    public int nextInt() {
        return Integer.parseInt(next());
    }
}

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
public class codeforces{

    public static int solve(int r,int x1,int y1,int x2,int y2){
        double d=(x2-x1)*(x2-x1);
        d=d+(y2-y1)*(y2-y1);
        d=Math.sqrt(d);
        // System.out.println(d);
        return (int)Math.ceil(d/(2*r));
    }

    public static void main(String[] args) throws IOException {
        InputStreamReader isr=new InputStreamReader(System.in);
        BufferedReader br=new BufferedReader(isr);
        // StringBuilder str=new StringBuilder();
        PrintWriter out=new PrintWriter(System.out);
        // int n=Integer.parseInt(br.readLine());
        String[] lol=br.readLine().split(" ");
        int r=Integer.parseInt(lol[0]);
        int x1=Integer.parseInt(lol[1]);
        int y1=Integer.parseInt(lol[2]);
        int x2=Integer.parseInt(lol[3]);
        int y2=Integer.parseInt(lol[4]);
        out.println(solve(r,x1,y1,x2,y2));
        out.close();
    }
}

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
//package amr;

import java.util.Scanner;

/**
 *
 * @author Admin
 */
public class Amr {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        Scanner s=new Scanner(System.in);
        double radius = s.nextInt();
        double x1 = s.nextInt();
        double y1 = s.nextInt();
        double x2 = s.nextInt();
        double y2 = s.nextInt();
        double diag=Math.sqrt((x2-x1)*(x2-x1)+(y2-y1)*(y2-y1));
        System.out.println(diag);
        double steps=0;
        double dis=Math.abs(x2-x1)+Math.abs(y2-y1);
        if(x2-x1 == y2-y1 && y2-y1>0)
            steps=Math.abs(x2-x1)/radius;
        else if(Math.abs(x2-x1) == y2-y1 && y2-y1<0)
            steps=-1*(x2-x1)/radius;
        else if(x2-x1 == y2-y1 && y2-y1 ==0)
            steps=0;
        else if(diag<radius)
            steps=1;
        else { while(diag>0){
            diag=diag-2*radius;
            steps++;
        }
        }

        System.out.println((int)steps);
    }

}

import java.util.Scanner;

public class B507 {
    public static Scanner input=new Scanner(System.in);
    public static void main(String[] args) {
        int rad=input.nextInt();
        int nowX=input.nextInt();
        int nowY=input.nextInt();
        int reqX=input.nextInt();
        int reqY=input.nextInt();
        double distance=Math.sqrt(Math.pow(nowX-reqX,2)+Math.pow(nowY-reqY,2));
        //System.out.println(distance);
        int ans=0;
        if(distance==0) {
            System.out.println(0);
            return;
        }
        else
            if(distance<rad) {
                System.out.println(1);
                return;
            }
            else{
                if(distance%rad>1){
                    ans++;
                    //System.out.println("im here");
                }
                ans+=distance/rad;
                ans--;
                System.out.println(ans);
            }
    }
}

import java.util.Scanner;
import java.util.*;
public class A490 {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
         Scanner s = new Scanner(System.in);
        int r = s.nextInt();
        int x = s.nextInt();
        int y = s.nextInt();
        int x1 = s.nextInt();
        int y1 = s.nextInt();
        double r1 = Math.sqrt(Math.pow(x-x1,2)+Math.pow(y-y1,2))-r;
        if(x==x1 && y==y1){
            System.out.println(0);
            return;

        }
        if(r1<r){
            System.out.println(1);
            return;
        }
        if(r1/r==0){
            System.out.println(1);
        }else{
            if(r1%r==0){
                System.out.println((int)(r1/r));
            }else{
                System.out.println((int)r1/r);
            }
        }

	}

}