from math import sqrt, ceil

r, x, y, x1, y1 = map(int, raw_input().split())

distance = sqrt((x-x1)**2 + (y-y1)**2)
steps = 0

if int(distance)%3*r == 0:
    steps = ceil(distance/3*r)
if int(distance) <= 3*r:
    if int(distance) == 0:
        steps = 0
    else:
        steps = 1
else:
    steps = ceil(distance/3*r) + 1

print int(steps)        

