import sys read = sys.stdin.buffer.read readline = sys.stdin.buffer.readline readlines = sys.stdin.buffer.readlines a,b,c,d = map(int,read().split()) x = abs(a-c) + abs(b-d) print(x/2)