import std.algorithm, std.container, std.conv, std.math, std.range, std.typecons, std.stdio, std.string;

auto rdsp(){return readln.splitter;}
void pick(R,T)(ref R r,ref T t){t=r.front.to!T;r.popFront;}
void readV(T...)(ref T t){auto r=rdsp;foreach(ref v;t)pick(r,v);}
void readC(T...)(size_t n,ref T t){foreach(ref v;t)v=new typeof(v)(n);foreach(i;0..n){auto r=rdsp;foreach(ref v;t)pick(r,v[i]);}}

void main()
{
  int n, a, b; readV(n, a, b); --a; --b;
  long[] x, y; readC(n, x, y);

  auto d = (x[a]-x[b]).abs + (y[a]-y[b]).abs;

  struct P { long x, y; int i; }
  auto p = new P[](n);
  foreach (i; 0..n) p[i] = P(x[i], y[i], i);

  P[][long] xpy, xmy;
  foreach (pi; p) {
    xpy[pi.x+pi.y] ~= pi;
    xmy[pi.x-pi.y] ~= pi;
  }

  foreach (i; xpy.byKey) xpy[i].sort!"a.x < b.x";
  foreach (i; xmy.byKey) xmy[i].sort!"a.x < b.x";

  auto calc(P u)
  {
    auto ux = u.x, uy = u.y;
    auto v1 = xpy.get(ux+uy+d, []).assumeSorted!"a.x < b.x".upperBound(P(ux-1, 0, 0)).lowerBound(P(ux+d, 0, 0));
    auto v2 = xmy.get(ux-uy+d, []).assumeSorted!"a.x < b.x".upperBound(P(ux, 0, 0)).lowerBound(P(ux+d+1, 0, 0));
    auto v3 = xpy.get(ux+uy-d, []).assumeSorted!"a.x < b.x".upperBound(P(ux-d-1, 0, 0)).lowerBound(P(ux, 0, 0));
    auto v4 = xmy.get(ux-uy-d, []).assumeSorted!"a.x < b.x".upperBound(P(ux-d, 0, 0)).lowerBound(P(ux+1, 0, 0));
    return [v1, v2, v3, v4];
  }

  auto vt = new bool[](n);
  vt[a] = vt[b] = true;

  auto q = DList!int(a, b);
  while (!q.empty) {
    auto qi = q.front; q.removeFront();
    auto u = p[qi];

    foreach (v; calc(u).joiner.filter!(v => !vt[v.i])) {
      vt[v.i] = true;
      q.insertBack(v.i);
    }
  }

  auto ans = 0L;
  foreach (i; 0..n)
    if (vt[i])
      ans += calc(p[i]).map!(v => v.length).sum;
  writeln(ans/2);
}
