#include <bits/stdc++.h>
using namespace std;
double area(pair<double, double> A, pair<double, double> B,
            pair<double, double> C) {
  double res = 0 * 1.0;
  res += A.first * B.second;
  res += B.first * C.second;
  res += C.first * A.second;
  res -= A.second * B.first;
  res -= B.second * C.first;
  res -= C.second * A.first;
  return res;
}
struct punto {
  pair<double, double> P;
  double ang;
  punto() {}
  punto(pair<double, double> X, double W) {
    P = X;
    ang = W;
  }
};
bool operator<(punto A, punto B) {
  if (A.ang != B.ang) return A.ang < B.ang;
  return A.P < B.P;
}
punto V[100000 * 5];
bool usd[100000 * 5];
int main() {
  int N;
  int dr[4] = {-1, 0, 1, 0};
  int dc[4] = {0, 1, 0, -1};
  int i, j, d;
  int p, q, r, r2;
  pair<double, double> W =
      pair<double, double>((1 << 30) * 1.0, (1 << 30) * 1.0);
  pair<double, double> ant;
  int res;
  scanf("%d", &N);
  for (i = 0; i < N; i++) {
    scanf("%lf%lf", &V[i * 5].P.first, &V[i * 5].P.second);
    usd[i * 5] = 1;
    V[i * 5].ang = 1.0 * 0;
    if (V[i * 5].P < W) {
      W = V[i * 5].P;
    }
    for (d = 0; d < 4; d++) {
      V[i * 5 + d + 1] = V[i * 5];
      V[i * 5 + d + 1].P.first += dr[d];
      V[i * 5 + d + 1].P.second += dc[d];
      usd[i * 5 + d + 1] = 1;
      V[i * 5 + d + 1].ang = 1.0 * 0;
      if (V[i * 5 + d + 1].P < W) {
        W = V[i * 5 + d + 1].P;
      }
    }
  }
  N *= 5;
  for (i = 0; i < N; i++) {
    if (V[i].P != W)
      V[i].ang = ((V[i].P.second - W.second) / (V[i].P.first - W.first));
    else
      V[i].ang = -(1 << 20) * 1.0;
  }
  sort(V, V + N);
  p = 0;
  q = 1;
  r = 2;
  do {
    if (area(V[p].P, V[q].P, V[r].P) >= 1.0 * 0) {
      p = q;
      q = r;
      r2 = (r + 1) % N;
      while (V[r].P == V[r2].P) {
        usd[r2] = 0;
        r2 = (r2 + 1) % N;
      }
      r = r2;
    } else {
      usd[q] = 0;
      q = p;
      p--;
      while (!usd[p]) p--;
    }
  } while (r > 0 && q > 0 && r > 0);
  ant = V[0].P;
  res = 0;
  for (i = 1; i < N; i++) {
    if (usd[i] && V[i].P != ant) {
      res += int(
          max(abs(ant.first - V[i].P.first), abs(ant.second - V[i].P.second)));
      ant = V[i].P;
    }
  }
  res +=
      int(max(abs(ant.first - V[0].P.first), abs(ant.second - V[0].P.second)));
  printf("%d\n", res);
  return 0;
}
