x,y=map(int,input().split()) a,b=map(int,input().split()) print((abs(a-x)+abs(b-y))/2)