#include <bits/stdc++.h>
int main() {
  int x1, y1, x2, y2;
  while (scanf("%d%d%d%d", &x1, &y1, &x2, &y2) != EOF) {
    int move = 0;
    int n = x1 > x2 ? (x1 - x2) : (x2 - x1);
    int m = y1 > y2 ? (y1 - y2) : (y2 - y1);
    move = n > m ? n : m;
    printf("%d\n", move);
  }
  return 0;
}
