import math
a = [int(i) for i in input().split()]
b = math.sqrt((a[1] - a[3]) ** 2 + (a[2] - a[4]) ** 2)
if(b == 0): 
    print(0) 
    exit(0)
if(b % a[0] == 0 or b % a[0] < 1):
    print(int(b / a[0]) - 1)
else:
    print(int(b / a[0]))