a, b, c, d = map(int, input().split()) dx = abs(a - c) dy = abs(b - d) result = max(dx, dy) print(result)