#include using namespace std; int main() { ios::sync_with_stdio(false); cin.tie(0); int px, py, qx, qy; cin >> px >> py >> qx >> qy; int sum = abs(px - qx) + abs(py - qy); cout << fixed << setprecision(20) << sum / 2 + (sum % 2 == 0 ? 0 : 0.5) << '\n'; return 0; }