// Copyright (C) 2016 __debug.

// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License as
// published by the Free Software Foundation; version 3

// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License
// along with this program; If not, see <http://www.gnu.org/licenses/>.


#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <cmath>
#include <cctype>
#include <climits>
#include <cassert>
#include <ctime>
#include <iostream>
#include <fstream>
#include <algorithm>
#include <functional>
#include <string>

#define x first
#define y second
#define MP std::make_pair
#define DEBUG(...) fprintf(stderr, __VA_ARGS__)
#ifdef __linux__
#define getchar getchar_unlocked
#define putchar putchar_unlocked
#endif

typedef long long LL;
typedef std::pair<int, int> Pii;

const int oo = 0x3f3f3f3f;

template<typename T> inline bool chkmax(T &a, T b) { return a < b ? a = b, true : false; }
template<typename T> inline bool chkmin(T &a, T b) { return b < a ? a = b, true : false; }
std::string procStatus()
{
    std::ifstream t("/proc/self/status");
    return std::string(std::istreambuf_iterator<char>(t), std::istreambuf_iterator<char>());
}
template<typename T> T read(T &x)
{
    int f = 1;
    char ch = getchar();
    for (; !isdigit(ch); ch = getchar())
        if (ch == '-')
            f = -1;
    for (x = 0; isdigit(ch); ch = getchar())
        x = 10 * x + ch - '0';
    return x *= f;
}
template<typename T> void write(T x)
{
    if (x == 0) {
        putchar('0');
        return;
    }
    if (x < 0) {
        putchar('-');
        x = -x;
    }
    static char s[20];
    int top = 0;
    for (; x; x /= 10)
        s[++top] = x % 10 + '0';
    while (top)
        putchar(s[top--]);
}
// EOT

#include <set>

const int MAXN = 1e5 + 5;

struct Point {
    std::pair<LL, LL> p;
    int id;

    friend bool operator< (const Point &a, const Point &b)
    {
        return a.p < b.p;
    }
};

int N, A, B;
Point P[MAXN];
int fa[MAXN], cnt[MAXN];

int getFather(int u)
{
    return fa[u] == u ? u : fa[u] = getFather(fa[u]);
}

void getEdges(LL D, int eq)
{
    static std::pair<LL, int> list[MAXN];
    static int otosan[MAXN];
    int size = 0;

    memset(otosan, 0, sizeof(otosan));
    std::sort(P + 1, P + N + 1);
    P[0].p.x = INT_MIN;

    for (int i = 1, j = 1, l = 0, r = 0; i <= N; ++i) {
        int cur = P[i].id;
        LL lb = P[i].p.y - D + eq;
        LL ub = P[i].p.y + D - eq;
        if (P[i].p.x != P[i - 1].p.x) {
            while (P[j].p.x + D < P[i].p.x) ++j;
            size = 0;
            for (; P[j].p.x + D == P[i].p.x; ++j) {
                list[size++] = MP(P[j].p.y, P[j].id);
            }
            std::sort(list, list + size);
            l = std::lower_bound(list, list + size, MP(lb, 0)) - list;
            r = std::upper_bound(list, list + size, MP(ub, +oo)) - list;
            for (int k = l; k < r; ++k) {
                otosan[list[k].y] = cur;
            }
        } else {
            int r0 = r;
            for (; r < size && list[r].x <= ub; ++r) {
                if (list[r].x >= lb)
                    otosan[list[r].y] = cur;
            }
            while (l < size && list[l].x < lb) ++l;
            if (l < r0)
                fa[getFather(cur)] = getFather(P[i - 1].id);
        }
        cnt[cur] += r - l;
    }
    for (int i = 1; i <= N; ++i) {
        if (otosan[i])
            fa[getFather(i)] = getFather(otosan[i]);
    }
}

void input()
{
    read(N); read(A); read(B);
    for (int i = 1; i <= N; ++i) {
        read(P[i].p.x); read(P[i].p.y);
        P[i].id = i;
    }
}

void solve()
{
    for (int i = 1; i <= N; ++i) {
        fa[i] = i;
    }

    LL D = std::abs((LL)P[A].p.x - P[B].p.x) + std::abs((LL)P[A].p.y - P[B].p.y);

    for (int i = 1; i <= N; ++i) {
        P[i].p = MP(P[i].p.x + P[i].p.y, P[i].p.x - P[i].p.y);
    }
    getEdges(D, 0);
    for (int i = 1; i <= N; ++i) {
        std::swap(P[i].p.x, P[i].p.y);
    }
    getEdges(D, 1);

    LL ans = 0;
    int rt = getFather(A);
    for (int i = 1; i <= N; ++i) {
        if (getFather(i) == rt)
            ans += cnt[i];
    }

    write(ans); putchar('\n');
}

int main()
{
#ifdef __DEBUG
    freopen("E.in", "r", stdin);
    freopen("E.out", "w", stdout);
#endif

    input();
    solve();

    return 0;
}


Measured memory_bytes: 4608