p1, p2 = map(int, input().split()) q1, q2 = map(int, input().split()) print ((abs(q1 - p1) + abs(q2 - p2))/2)