import math

def cordis(a1,b1,a2,b2,r):
    asq = (a2 - a1)**2
    bsq = (b2 -b1)**2
    return (math.sqrt(asq + bsq) - 2*r)
    
inplt = list(map(int , input().split()))
r , x1 , y1 , x2 , y2 = [i for i in inplt]

if (x1 == x2) and (y1 == y2):
    print(0)
else:
    dip = cordis(x1,y1,x2,y2,r)
    if dip <= 0:
        print(1)
    else:
        stp = math.ceil(dip/(2*r))
        print(stp+1)