from math import sqrt
r,x,y,a,b, = map(int,input().split())
dist = sqrt(((x-a)**2)+(y-b)**2)
if dist == 0:
    print(0)
elif divmod(dist,2*r)[1]>0 and dist>0:
    print(int(divmod(dist,2*r)[0])+int(divmod(dist,2*r)[1])+1)
else:
     print(int(divmod(dist,2*r)[0])+int(divmod(dist,2*r)[1]))