#include<bits/stdc++.h>
using namespace std;
const int maxn = 1e5 + 5;
struct lpl{
	int x, y, id;
	bool operator < (const lpl &A)const{return (x == A.x) ? (y < A.y) : (x < A.x);}
	bool operator <= (const lpl &A)const{return (x == A.x) ? (y <= A.y) : (x < A.x);}
}point[maxn], lower;
struct ld{
	int x, y;
	bool operator < (const ld &A)const{return (x == A.x) ? (y < A.y) : (x < A.x);}
};
int fa[maxn];
long long ans[maxn], siz[maxn];
int n, a, b, d;
map<ld, int> mp;

int find(int t){return (t == fa[t]) ? (t) : (fa[t] = find(fa[t]));}

inline void connect(int a, int b){
	a = point[a].id; b = point[b].id;
	a = find(a); b = find(b); fa[a] = b;
}

inline void workk(){
	int L = 0, R = 0;
	sort(point + 1, point + n + 1);
	for(int i = 1; i <= n; ++i){
		lower.x = point[i].x - d; lower.y = point[i].y - d;
		int lin = lower_bound(point + 1, point + n + 2, lower) - point;
		L = max(lin, R); R = L; 
		if(point[L].x == lower.x && point[L].y <= point[i].y + d) 
			connect(i, L);
		while(point[R + 1].x + d == point[i].x && point[R + 1].y <= point[i].y + d){
			connect(R, R + 1); R++;
		}
		ans[point[i].id] += (R - lin + 1); 
		if(point[lin].x != lower.x || point[lin].y > point[i].y + d) ans[point[i].id]--;
	}
}

inline void check(){
	for(int i = 1; i <= n; ++i) printf("i = %d x = %d y = %d\n", i, point[i].x, point[i].y);
	printf("\n");
}

int main()
{
	//freopen("lpl.in", "r", stdin);
	scanf("%d%d%d", &n, &a, &b); point[n + 1].x = point[n + 1].y = 2e9;
	for(int x, y, i = 1; i <= n; ++i){
		scanf("%d%d", &x, &y);
		point[i].x = x + y; point[i].y = x - y; point[i].id = i;
		mp[(ld){point[i].x, point[i].y}]++;
	}
	d = max(abs(point[a].x - point[b].x), abs(point[a].y - point[b].y));
	for(int i = 1; i <= n; ++i){
		if(mp[(ld){point[i].x - d, point[i].y - d}]) ans[i]--;
		if(mp[(ld){point[i].x - d, point[i].y + d}]) ans[i]--;
	}
	for(int i = 1; i <= n; ++i) fa[i] = i;
	//check();
	workk();
	//printf("d = %d\n", d);
	//for(int i = 1; i <= n; ++i) printf("ans[%d] = %lld\n", i, ans[i]);
	for(int i = 1; i <= n; ++i) swap(point[i].x, point[i].y);
	//check();
	workk();
	//for(int i = 1; i <= n; ++i) printf("ans[%d] = %lld\n", i, ans[i]);
	//for(int i = 1; i <= n; ++i) printf("fa[%d] = %d\n", i, find(i));
	for(int i = 1; i <= n; ++i) siz[find(i)] += ans[i];
	cout << siz[find(a)];
	return 0;
}