#include <bits/stdc++.h>

using namespace std;


typedef long long ll;
typedef pair<ll,ll> ii;
#define X first
#define Y second

const int N=1e5+10;


int n,sp1,sp2;
ll d;


ll p[2][N];

queue <int> q;

vector <int> v[2][N];
set <ii> mse;
int h[N];
ll a[N][2];
int nextp[N][2];
int per[N];
bool comp0(int x,int y){
    return a[x][0]<a[y][0];
}
bool comp1(int x,int y){
    return a[x][1]<a[y][1];
}
int getp(int type,int x){
    if (!h[x]) return x;
    return nextp[x][type]=getp(type,nextp[x][type]);
}
int mcount(int type,ll pos,ll L,ll R){
    int idx=lower_bound(p[type]+1,p[type]+n+1,pos)-p[type];
    if (idx>n||p[type][idx]!=pos) return 0;

    int n1=v[type][idx].size();
    int LL=0,LR=n1-1;
    while (LL<=LR){
        int mid=(LL+LR)/2;
        int cur=v[type][idx][mid];
//        cout<<mid<<" "<<cur<<" "<<LL<<" "<<LR<<'\n';
        if (a[cur][type^1]>=L) LR=mid-1;
        else LL=mid+1;
    }
    int RL=0,RR=n1-1;
    while (RL<=RR){
        int mid=(RL+RR)/2;
        int cur=v[type][idx][mid];
        if (a[cur][type^1]<=R) RL=mid+1;
        else RR=mid-1;
    }
    int ans=RL-LL;
    if (LL>=n1) return ans;
    int cur=v[type][idx][LL];
//    cout<<type<<" "<<pos<<" "<<n1<<" "<<L<<" "<<R<<" "<<cur<<'\n';
    while (1){
        cur=getp(type,cur);
//        cout<<">"<<cur<<'\n';
        if (!cur) break;
        if (a[cur][type^1]>R) break;
//        cout<<"=>"<<type<<" "<<pos<<" "<<L<<" "<<R<<" "<<cur<<'\n';
        h[cur]=1;
        q.push(cur);
    }
    return ans;
}
int inqueue(int idx){
    int ans=0;
    ll rx=a[idx][0],ry=a[idx][1];
    ans-=mse.count(ii(rx-d,ry+d));
    ans-=mse.count(ii(rx+d,ry+d));
    ans-=mse.count(ii(rx-d,ry-d));
    ans-=mse.count(ii(rx+d,ry-d));
    ans+=mcount(0,rx+d,ry-d,ry+d);
    ans+=mcount(0,rx-d,ry-d,ry+d);
    ans+=mcount(1,ry-d,rx-d,rx+d);
    ans+=mcount(1,ry+d,rx-d,rx+d);
    return ans;
}
ll solve(){
    ll ans=0;
    h[sp1]=h[sp2]=1;
    q.push(sp1);
    q.push(sp2);
    while (!q.empty()){
        int x=q.front();q.pop();
//        cout<<x<<'\n';
        ans+=inqueue(x);
    }
    return ans/2;
}


int main(){
    scanf("%d%d%d",&n,&sp1,&sp2);
    for(int i=1;i<=n;i++){
        int x,y;
        scanf("%d%d",&x,&y);
        a[i][0]=x+y,a[i][1]=y-x;
    }
//    for(int i=1;i<=n;i++) cout<<a[i][0]<<" "<<a[i][1]<<'\n';
    for(int i=1;i<=n;i++) mse.insert(ii(a[i][0],a[i][1]));


    ///
    d=max(abs(a[sp1][0]-a[sp2][0]),abs(a[sp1][1]-a[sp2][1]));
//    cout<<d<<'\n';
    for(int j=0;j<=1;j++){
        for(int i=1;i<=n;i++) p[j][i]=a[i][j];
        sort(p[j]+1,p[j]+n+1);
    }

    for(int i=1;i<=n;i++) per[i]=i;
    ///
    sort(per+1,per+n+1,comp1);
    for(int j=1;j<=n;j++) {
        int i=per[j];
        int idx=lower_bound(p[0]+1,p[0]+n+1,a[i][0])-p[0];
        v[0][idx].push_back(i);
    }
    sort(per+1,per+n+1,comp0);
    for(int j=1;j<=n;j++){
        int i=per[j];
        int idx=lower_bound(p[1]+1,p[1]+n+1,a[i][1])-p[1];
        v[1][idx].push_back(i);
    }
    for(int j=0;j<=1;j++)
        for(int i=1;i<=n;i++) if (!v[j][i].empty()){
            int n1=v[j][i].size();
            for(int i1=0;i1<n1-1;i1++) nextp[v[j][i][i1]][j]=v[j][i][i1+1];
        }
    cout<<solve();
}


Measured memory_bytes: 21248