// Slower C++ solution:
#include<bits/stdc++.h>

#define sz(x) ((int)(x).size())

#define all(x) (x).begin(),(x).end()

#define rep(i,a,b) for (int i=(a); i<(b); i++)

#define per(i,a,b) for (int i=(b-1); i>=(a); i--)

#define debug(x) cout << #x << " => " << x << endl

using namespace std;



#define fi first

#define se second

#define mp make_pair

typedef pair<int,int> pii;



#define eb emplace_back

#define pb push_back

typedef vector<int> vi;



typedef long long ll;

typedef long double ld;



const int MAX_N = 7 + 100000;

///----------------------------------------------

map<int, vector<pii> > v1,v2;

map<int, set<pii> > s1,s2;

int x[MAX_N], y[MAX_N], n,D;

bool vis[MAX_N];

///----

int solve(vector<pii> &hv, int lo, int hi) {

	auto itl = lower_bound(all(hv), mp(lo,-1));

	auto itr = lower_bound(all(hv), mp(hi+1,-1));

	return itr-itl;

}

void check(set<pii> &hv, int lo, int hi, queue<int> &que) {

	auto it = hv.lower_bound(mp(lo, -1));

	while (it != hv.end() && it->fi <= hi) {

		if (!vis[it->se]) que.push(it->se);

		vis[it->se] = true;

		it = hv.erase(it);

	}

}

///----

void bfs(int st) {

	queue<int> que;

	que.push(st); vis[st]=true;

	for (; !que.empty(); ) {

		int at = que.front(); que.pop();

		auto it = s1.find(x[at]+y[at]-D); if (it != s1.end()) check(it->se, x[at]-D, x[at], que);

			 it = s1.find(x[at]+y[at]+D); if (it != s1.end()) check(it->se, x[at], x[at]+D, que);

			 it = s2.find(x[at]-y[at]-D); if (it != s2.end()) check(it->se, x[at]-D+1, x[at]-1, que);

			 it = s2.find(x[at]-y[at]+D); if (it != s2.end()) check(it->se, x[at]+1, x[at]+D-1, que);

	}

}

///----

int main() {

	

	///read

	int a,b; scanf("%d%d%d",&n,&a,&b); a--; b--;

	rep(i,0,n) {

		scanf("%d%d",x+i,y+i);

		v1[x[i]+y[i]].eb(x[i],i);

		v2[x[i]-y[i]].eb(x[i],i);

		s1[x[i]+y[i]].emplace(x[i], i);

		s2[x[i]-y[i]].emplace(x[i], i);

	}



	///prework

	for (auto it = v1.begin(); it != v1.end(); it++) sort(all(it->se));

	for (auto it = v2.begin(); it != v2.end(); it++) sort(all(it->se));

	D = abs(x[a]-x[b])+abs(y[a]-y[b]);



	///work

	memset(vis,false,sizeof(vis));

	bfs(a); bfs(b);

	ll ans=0;

	rep(i,0,n) if (vis[i]) {

		auto it = v1.find(x[i]+y[i]-D); if (it != v1.end()) ans += solve(it->se, x[i]-D, x[i]);

			 it = v1.find(x[i]+y[i]+D); if (it != v1.end()) ans += solve(it->se, x[i], x[i]+D);

			 it = v2.find(x[i]-y[i]-D); if (it != v2.end()) ans += solve(it->se, x[i]-D+1, x[i]-1);

			 it = v2.find(x[i]-y[i]+D); if (it != v2.end()) ans += solve(it->se, x[i]+1, x[i]+D-1);

	}

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

	

	return 0;







}


// Faster C++ solution for the same problem (measured speedup: 1.2022159737547355x):
//yhn's

#include<cstdio>

#include<cstring>

#include<algorithm>

#include<cmath>

#include<vector>

using namespace std;



typedef long long ll;

const int MAXN=2e5+5;



int n;

int fa[MAXN];

ll d,siz[MAXN],cnt[MAXN];

vector<pair<ll,int> > mp;

struct node{

    ll x,y;

    int id;

    bool operator < (const node &a) const{

        if(x==a.x) return y<a.y;

        return x<a.x;

    }

}p[MAXN];



int find(int x){

    if(fa[x]==x) return x;

    return fa[x]=find(fa[x]);

}



ll dis(int x,int y){

    return abs(p[x].x-p[y].x)+abs(p[x].y-p[y].y);

}



void work(int now){

    mp.clear();

    vector<pair<ll,int> >::iterator lasx,it;

    int las=1,flag=0;

    for(int i=1;i<=n;i++){

        if(p[i].x!=p[i-1].x){

            mp.clear();

            flag=1;

        }

        while(p[i].x-p[las].x>d&&las<=n) las++;

        while(p[i].x-p[las].x==d&&las<=n){

            mp.push_back(make_pair(p[las].y,p[las].id));

            las++;

        }

        it=lower_bound(mp.begin(),mp.end(),make_pair(p[i].y-d+now,0));

        if(it==mp.end()||it->first>p[i].y+d-now) continue;

        if(flag){

            flag=0;

            lasx=mp.begin();

        }

        lasx=max(lasx,it);

        for(;lasx!=mp.end()&&lasx->first<=p[i].y+d-now;lasx++){

            int x=lasx->second;

            int y=p[i].id;

            if(find(x)!=find(y))

                fa[find(x)]=find(y);

        }

        cnt[p[i].id]+=lasx-it;

        if(lasx!=it) lasx--;

    }

}



int main(){

    int a,b;

    scanf("%d%d%d",&n,&a,&b);

    for(int i=1;i<=n;i++)

        scanf("%lld%lld",&p[i].x,&p[i].y),p[i].id=i;

    for(int i=1;i<=n;i++) fa[i]=i;

    d=dis(a,b);

    for(int i=1;i<=n;i++){

        int x=p[i].x,y=p[i].y;

        p[i].x=x-y;

        p[i].y=x+y;

    }

    sort(p+1,p+n+1);

    work(0);

    for(int i=1;i<=n;i++)

        swap(p[i].x,p[i].y);

    sort(p+1,p+n+1);

    work(1);

    for(int i=1;i<=n;i++)

        siz[find(i)]+=cnt[i];

    printf("%lld",siz[find(a)]);

}