#include <iostream>
#include <cstdio>
#include <cstring>
#include <algorithm>
#include <vector>
#include <cstdlib>
using namespace std;
const int MAXN = 200005;
typedef long long ll;
struct Node{
	ll x,y;
	int id;
	bool operator < (const Node &b)const
	{
		return x==b.x?y<b.y:x<b.x;
	}
}a[MAXN],t[MAXN];
int tot,n;
ll d;
int now,front,back,sa,sb,fa[MAXN];
ll ans[MAXN];
int getan(int x)
{
	return x==fa[x]?x:fa[x]=getan(fa[x]);
}
#define NEXT {++back;continue;}
void solve(int delta)
{
	front=1,back=0;
	int end=0,last=0;
	a[0].x=-998244353;
	for(int i=1;i<=n;++i){
		if(a[i].x!=a[i-1].x){
			while(front<=back && a[front].x+d<a[i].x)++front;
			if(a[front].x+d>a[i].x || front>back)NEXT;
			end=front;
			while(end<back && a[end+1].x+d==a[i].x)++end;
			tot=last=0;
			if(a[end].x+d==a[i].x){
				last=1;
				for(int i=front;i<=end;++i)t[++tot]=a[i],++front;
			}	
		}
		if(a[end].x+d==a[i].x){
			int pos=lower_bound(t+1,t+tot+1,(Node){a[i].x-d,a[i].y-d-delta,a[i].id})-t;
			last=max(last,pos);
			if(pos==tot+1 || t[last].y>a[i].y+d+delta)NEXT;
			for(;last<=tot && t[last].y<=a[i].y+d+delta;++last){
				fa[getan(a[i].id)]=getan(t[last].id);
			}
			ans[a[i].id]+=last-pos;
			if(last!=pos)--last;
		}
		++back;
	}

}
ll final_ans[MAXN],sx,sy,tx,ty;
int main()
{
	scanf("%d%d%d",&n,&sa,&sb);
	for(int i=1,x,y;i<=n;++i){
		fa[i]=i;
		scanf("%d%d",&x,&y);
		a[i].x=x-y,a[i].y=x+y;
		a[i].id=i;
		if(i==sa)sx=x,sy=y;
		if(i==sb)tx=x,ty=y;
	}
	d=abs(sx-tx)+abs(sy-ty);
	sort(a+1,a+n+1);
	solve(0);
	for(int i=1;i<=n;++i)swap(a[i].x,a[i].y);
	sort(a+1,a+n+1);
	solve(-1);
	for(int i=1;i<=n;++i)final_ans[getan(i)]+=ans[i];
	cout<<final_ans[getan(sa)]<<endl;
	return 0;
}
