import math

r, x1, y1, x2, y2 = map(int, input().split())

u = abs(x2 - x1)
v = abs(y2 - y1)

l = math.ceil(math.sqrt(u*u + v*v))

res = l / (2 * r)

if (int(res) == 0):
  res = 0
else:
  if res % int(res) != 0:
    res = int(res) + 1

print(int(res))