PX, PY = map(int, input().split()) QX, QY = map(int, input().split()) print((abs(PX - QX) + abs(PY - QY)) / 2)