#include <bits/stdc++.h>
using namespace std;
long long int n;
long long int X[100500];
long long int Y[100500];
long long int TYPE[100500];
int main() {
  long long int n;
  cin >> n;
  for (long long int i = 0; i < ((long long int)(n)); ++i) cin >> X[i] >> Y[i];
  vector<pair<long long int, long long int> > dx, dy;
  for (long long int i = 0; i < ((long long int)(n)); ++i)
    dx.push_back(make_pair(X[i], i));
  for (long long int i = 0; i < ((long long int)(n)); ++i)
    dy.push_back(make_pair(Y[i], i));
  sort((dx).begin(), (dx).end());
  sort((dy).begin(), (dy).end());
  long long int ans = -1;
  for (long long int step = 0; step < ((long long int)(4)); ++step) {
    memset(TYPE, 0, sizeof(TYPE));
    long long int VX = (n + step % 2) / 2;
    long long int VY = (n + step / 2) / 2;
    for (long long int i = 0; i < ((long long int)(VX)); ++i)
      TYPE[dx[i].second] |= 1;
    for (long long int i = 0; i < ((long long int)(VY)); ++i)
      TYPE[dy[i].second] |= 2;
    long long int MX = dx[VX - 1].first;
    long long int MY = dy[VY - 1].first;
    long long int sum = 0;
    for (long long int i = 0; i < ((long long int)(n)); ++i)
      sum += abs(MX - dx[i].first) * 2;
    for (long long int i = 0; i < ((long long int)(n)); ++i)
      sum += abs(MY - dy[i].first) * 2;
    long long int type_cnt[4] = {0, 0, 0, 0};
    for (long long int i = 0; i < ((long long int)(n)); ++i)
      type_cnt[TYPE[i]]++;
    if (n % 2 == 0) {
      long long int reduce = type_cnt[0] == 0 || type_cnt[1] == 0
                                 ? 0
                                 : (1ll << (long long int)(50));
      long long int mini0 = (1ll << (long long int)(50)),
                    mini1 = (1ll << (long long int)(50));
      for (long long int i = 0; i < ((long long int)(n)); ++i) {
        if (TYPE[i] & 1)
          mini0 = min(mini0, abs(MX - X[i]));
        else
          mini1 = min(mini1, abs(MX - X[i]));
      }
      reduce = min(reduce, mini0 * 2 + mini1 * 2);
      mini0 = (1ll << (long long int)(50)),
      mini1 = (1ll << (long long int)(50));
      for (long long int i = 0; i < ((long long int)(n)); ++i) {
        if (TYPE[i] & 2)
          mini0 = min(mini0, abs(MY - Y[i]));
        else
          mini1 = min(mini1, abs(MY - Y[i]));
      }
      reduce = min(reduce, mini0 * 2 + mini1 * 2);
      ans = max(ans, sum - reduce);
    } else {
      long long int target = 0;
      if (step % 2 == 1) target |= 1;
      if (step / 2 == 1) target |= 2;
      vector<pair<long long int, long long int> > DX;
      vector<pair<long long int, long long int> > DY;
      for (long long int i = 0; i < ((long long int)(n)); ++i)
        if (TYPE[i] == target) {
          DX.push_back(make_pair(abs(MX - X[i]), i));
          DY.push_back(make_pair(abs(MY - Y[i]), i));
        }
      sort((DX).begin(), (DX).end());
      sort((DY).begin(), (DY).end());
      for (long long int step = 0; step < ((long long int)(2)); ++step) {
        long long int miniX = (1ll << (long long int)(50));
        long long int miniY = (1ll << (long long int)(50));
        for (long long int i = 0; i < ((long long int)(n)); ++i)
          if ((TYPE[i] & 1) == (target & 1) && TYPE[i] != target)
            miniX = min(miniX, abs(MX - X[i]));
        for (long long int i = 0; i < ((long long int)(n)); ++i)
          if ((TYPE[i] & 2) == (target & 2) && TYPE[i] != target)
            miniY = min(miniY, abs(MY - Y[i]));
        if (((long long int)(DX).size()) == 1) {
          miniX = min(miniX, DX[0].first);
          miniY = min(miniY, DY[0].first);
        } else {
          miniX = min(miniX, DX[step].first);
          miniY = min(miniY, DY[DX[step].second == DY[0].second ? 1 : 0].first);
        }
        long long int result = sum - miniX * 2 - miniY * 2;
        ans = max(ans, result);
      }
    }
  }
  cout << ans << endl;
}
