#include<bits/stdc++.h>


using namespace std;

using ll   = long long;
using ii   = pair   < int , int >;
using i3   = pair   < int , ii  >;
using li   = pair   < ll  , int >;
using lii  = pair   < ll  , ii  >;
using pll  = pair   < ll  , ll  >;
using vi   = vector < int       >;
using vl   = vector < ll        >;
using vii  = vector < ii        >;
using vli  = vector < li        >;
using vpll = vector < pll       >;
using vi3  = vector < i3        >;
using vlii = vector < lii       >;


const int N = 2e5 + 5;
const ll INF = 1e17 + 7;
const double eps = 1e-9 , PI = acos(-1);



int n , m;

ll st[N << 2];
map < int , int > mp;

void build(int p , int l , int r) {
    if(l == r) {
            st[p] = -INF;
            return;
    }

    int mid = l + (r - l) / 2;

    build(p << 1 , l , mid);
    build(p << 1 | 1 , mid + 1 , r);

    st[p] = max(st[p << 1] , st[p << 1 | 1]);
}

void update(int p , int l , int r , int dx , ll val) {
    if(l == r) {
            st[p] = max(st[p] , val);
            return;
    }

    int mid = l + (r - l) / 2;

    if(dx <= mid) update(p << 1 , l , mid , val , dx);
    else update(p << 1 | 1 , mid + 1 , r , val , dx);

    st[p] = max(st[p << 1] , st[p << 1 | 1]);
}

ll query(int p , int l , int r , int S , int E) {
    if(l >= S && r <= E) return st[p];
    if(l > E || r < S) return -INF;

    int mid = l + (r - l) / 2;

    return max(query(p << 1 , l , mid , S , E) , query(p << 1 | 1 , mid + 1 , r , S , E));
}

void solve(int testCase){

    scanf("%d" , &n);

    vpll v;

    int cnt = 0;

    ll mx1 = -INF , mx2 = -INF , mn1 = INF , mn2 = INF;

    for(int i = 0 ; i < n ; i ++) {
            ll x , y;
            scanf("%lld %lld" , &x , &y);

            if(mp[x] == 0) {
                    mp[x] = ++ cnt;
            }

            v.push_back({y , x});

            mx1 = max(mx1 , x + y);
            mx2 = max(mx2 , x - y);

            mn1 = min(mn1 , x + y);
            mn2 = min(mn2 , x - y);
    }

    printf("%lld\n" , max( mx1 - mn1 , mx2 - mn2 ));
    return;

    sort(v.begin() , v.end());

    ll ans = 0ll;

    build(1 , 1 , N);

    //cout << "forward:\n";

    vpll tmp;
    for(int i = 0 ; i < n ; i ++) {

            if(i) {
                    if(v[i].first != v[i-1].first) {
                            while(!tmp.empty()) {
                                    ll x2 = tmp.back().second;
                                    ll y2 = tmp.back().first;

                                    update(1 , 1 , N , mp[x2] , x2 - y2);
                                    tmp.pop_back();
                            }
                    }
            }

            ll x = v[i].second;
            ll y = v[i].first;

            int dx = mp[x];

            ll val = query(1 , 1 , N , dx , N);

            //cout << x << " " << y << " " << val << endl;

            ans = max(ans , val - (x - y));

            tmp.push_back({y , x});
    }
    //cout << endl;

    build(1 , 1 , N);

    //cout << "backward:\n";
    for(int i = n-1 ; i >= 0 ; i --) {
            ll x = v[i].second;
            ll y = v[i].first;

            int dx = mp[x];

            ll val = query(1 , 1 , N , dx , N);

            //cout << x << " " << y << " " << val << endl;

            ans = max(ans , val - (x + y));

            update(1 , 1 , N , dx , x + y);
    }
    //cout << endl;

    printf("%lld\n" , ans);

}

main(){

    int t = 1;
    // scanf("%d" , &t);

    for(int testCase = 1 ; testCase <= t ; testCase ++){
            solve(testCase);
    }

    return 0;
}


Measured memory_bytes: 15828