#include <bits/stdc++.h>
using namespace std;
const int maxn = 4e5 + 233;
struct P {
  int x, y;
  P(int x = 0, int y = 0) : x(x), y(y) {}
};
double I = 1;
P operator+(P A, P B) { return P(A.x + B.x, A.y + B.y); }
P operator-(P A, P B) { return P(A.x - B.x, A.y - B.y); }
P operator*(P A, double t) { return P(A.x * t, A.y * t); }
P operator/(P A, double t) { return P(A.x / t, A.y / t); }
double dot(P A, P B) { return I * A.x * B.x + I * A.y * B.y; }
double cross(P A, P B) { return I * A.x * B.y - I * A.y * B.x; }
P a[maxn], b[maxn];
int dx[4] = {0, 0, 1, -1};
int dy[4] = {1, -1, 0, 0};
bool cmp(const P A, const P B) {
  if (A.x == B.x) return A.y < B.y;
  return A.x < B.x;
}
int my_abs(int a) {
  if (a > 0) return a;
  return -a;
}
int cal(P A, P B) { return max(my_abs(A.x - B.x), my_abs(A.y - B.y)); }
int main() {
  int n;
  cin >> n;
  int cnt = 0;
  for (int i = 1; i <= n; i++) {
    int x, y;
    scanf("%d%d", &x, &y);
    for (int j = 0; j < 4; j++) {
      int nx = x + dx[j];
      int ny = y + dy[j];
      a[++cnt] = P(nx, ny);
    }
  }
  sort(a + 1, a + 1 + cnt, cmp);
  int k = 0;
  for (int i = 1; i <= cnt; i++) {
    while (k > 1 && cross(a[i] - b[k - 1], a[i] - b[k]) >= 0) k--;
    b[++k] = a[i];
  }
  long long ans = 0;
  for (int i = 1; i < k; i++) ans += cal(b[i], b[i + 1]);
  k = 0;
  for (int i = cnt; i >= 1; i--) {
    while (k > 1 && cross(a[i] - b[k - 1], a[i] - b[k]) >= 0) k--;
    b[++k] = a[i];
  }
  for (int i = 1; i < k; i++) ans += cal(b[i], b[i + 1]);
  cout << ans << endl;
  return 0;
}
