#include <bits/stdc++.h>
#define fi first
#define se second
using namespace std;
typedef pair<int,int> ii;
typedef pair<ii, int> iii;
const int N = 200005;
int n, a, b;
int x[N], y[N];
vector<iii> v;
vector<int> adjlist[N];
queue<int> q;
int P[N];
int D;
int vis[N];
int ct[N];
long long ans;
void dfs(int u){
    for (auto v : adjlist[u]){
        if (vis[v] == 0){
            vis[v] = 1;
            //printf("%d %d\n",v,ct[v]);
            ans += ct[v];
            dfs(v);
        }
    }
}
int main(){
    scanf("%d%d%d",&n,&a,&b);
    for (int i = 1; i <= n; i++){
        scanf("%d%d",&x[i],&y[i]);
    }
    D = abs(y[a]-y[b]) + abs(x[b]-x[a]);
    v.clear();
    for (int i = 1; i <= n; i++){
        v.push_back({{x[i]-y[i],x[i]+y[i]},i});
    }
    sort(v.begin(),v.end());
    for (auto cur : v){
        int x = cur.fi.fi, y = cur.fi.se, id = cur.se;
        //printf("%d %d %d\n",x,y,id);
        auto l = lower_bound(v.begin(),v.end(),iii(ii(x+D,y-D),-1));
        auto r = --lower_bound(v.begin(),v.end(),iii(ii(x+D,y+D+1),-1));
        if (l->fi.fi == x+D && l->fi.se <= y+D){
            P[l-v.begin()+1]++; P[r-v.begin()+1]--;
            adjlist[id].push_back(l->se);
            adjlist[l->se].push_back(id);
        }


        l = lower_bound(v.begin(),v.end(),iii(ii(x+D,y-D+1),-1));
        r = --lower_bound(v.begin(),v.end(),iii(ii(x+D,y+D),-1));
        ct[id] += r-l+1;
        //printf("add %d\n",r-l+1);
        l = lower_bound(v.begin(),v.end(),iii(ii(x-D,y-D+1),-1));
        r = --lower_bound(v.begin(),v.end(),iii(ii(x-D,y+D),-1));
        ct[id] += r-l+1;
        //printf("add %d\n",r-l+1);
    }
    for (int i = 1; i < n; i++){
        P[i] += P[i-1];
        if (P[i] >= 1){
            //printf("%d %d, add\n",i,P[i]);
            //printf("union %d %d\n",v[i].se,v[i-1].se);
            adjlist[v[i].se].push_back(v[i-1].se);
            adjlist[v[i-1].se].push_back(v[i].se);
        }
    }
    v.clear();
    memset(P,0,sizeof(P));
    for (int i = 1; i <= n; i++){
        v.push_back({{x[i]+y[i],x[i]-y[i]},i});
    }
    sort(v.begin(),v.end());
    for (auto cur : v){
        int x = cur.fi.fi, y = cur.fi.se, id = cur.se;
        //printf("processing %d %d %d\n",x,y,id);
        auto l = lower_bound(v.begin(),v.end(),iii(ii(x+D,y-D),-1));
        auto r = --lower_bound(v.begin(),v.end(),iii(ii(x+D,y+D+1),-1));
        if (l->fi.fi == x+D && l->fi.se <= y+D){
            P[l-v.begin()+1]++; P[r-v.begin()+1]--;
            adjlist[id].push_back(l->se);
            adjlist[l->se].push_back(id);
        }

        ct[id] += r-l+1;
        //printf("add %d\n",r-l+1);
        l = lower_bound(v.begin(),v.end(),iii(ii(x-D,y-D),-1));
        r = --lower_bound(v.begin(),v.end(),iii(ii(x-D,y+D+1),-1));
        ct[id] += r-l+1;
        //printf("add %d\n",r-l+1);
    }
    for (int i = 1; i < n; i++){
        P[i] += P[i-1];
        if (P[i] >= 1){
            //printf("%d %d, add\n",i,P[i]);
            //printf("union %d %d\n",v[i].se,v[i-1].se);
            adjlist[v[i].se].push_back(v[i-1].se);
            adjlist[v[i-1].se].push_back(v[i].se);
        }
    }
    for (int i = 1; i <= n; i++){
        //printf("%d ct %d:\n",i,ct[i]);
        for (auto x : adjlist[i]){
            //printf("%d ",x);
        }
        //printf("\n");
    }
    dfs(a);
    printf("%lld",ans/2);

}


Measured memory_bytes: 18036