#include <bits/stdc++.h>
using namespace std;
const int mod = 1000000007;
int n;
pair<int, int> p[5555];
set<int> get(int x0, int y0, int x1, int y1) {
  if (x0 > x1) swap(x0, x1);
  if (y0 > y1) swap(y0, y1);
  set<int> res;
  for (int i(0); i < n; ++i)
    if (x0 <= p[i].first && p[i].first <= x1 && y0 <= p[i].second &&
        p[i].second <= y1)
      res.insert(i);
  return res;
}
bool check(const set<int> &A, const set<int> &B) {
  for (int i(0); i < n; ++i)
    if (!A.count(i) && !B.count(i)) return false;
  return true;
}
int common(const set<int> &A, const set<int> &B) {
  int res = 0;
  for (int i(0); i < n; ++i)
    if (A.count(i) && B.count(i)) ++res;
  return res;
}
bool check(int d) {
  int x0 = p[0].first, y0 = p[0].second, x1 = x0, y1 = y0;
  for (int i(0); i < n; ++i) {
    x0 = min(x0, p[i].first);
    y0 = min(y0, p[i].second);
    x1 = max(x1, p[i].first);
    y1 = max(y1, p[i].second);
  }
  set<int> A[4];
  A[0] = get(x0, y0, x0 + d, y0 + d);
  A[1] = get(x1, y0, x1 - d, y0 + d);
  A[2] = get(x0, y1, x0 + d, y1 - d);
  A[3] = get(x1, y1, x1 - d, y1 - d);
  for (int j(0); j < 4; ++j)
    for (int i(0); i < j; ++i)
      if (check(A[i], A[j])) return true;
  return false;
}
int count(int d) {
  int x0 = p[0].first, y0 = p[0].second, x1 = x0, y1 = y0;
  for (int i(0); i < n; ++i) {
    x0 = min(x0, p[i].first);
    y0 = min(y0, p[i].second);
    x1 = max(x1, p[i].first);
    y1 = max(y1, p[i].second);
  }
  set<int> A[4];
  A[0] = get(x0, y0, x0 + d, y0 + d);
  A[1] = get(x1, y0, x1 - d, y0 + d);
  A[2] = get(x0, y1, x0 + d, y1 - d);
  A[3] = get(x1, y1, x1 - d, y1 - d);
  int res = 0;
  set<pair<set<int>, set<int>>> U;
  for (int i(0); i < 4; ++i)
    for (int j(0); j < 4; ++j)
      if (check(A[i], A[j]) && U.count({A[i], A[j]}) == 0) {
        U.insert({A[i], A[j]});
        int k = common(A[i], A[j]), z = 1;
        for (; k > 0; --k)
          if ((z += z) >= mod) z -= mod;
        if ((res += z) >= mod) res -= mod;
      }
  return res;
}
int main() {
  cin >> n;
  for (int i(0); i < n; ++i) {
    int x, y;
    cin >> x >> y;
    p[i] = {x + y, x - y};
  }
  int L = 0, R = 20000, V;
  for (; L <= R;) {
    V = (L + R) / 2;
    check(V) ? R = V - 1 : L = V + 1;
  }
  cout << L << endl;
  cout << count(L) << endl;
  return 0;
}
