#include <bits/stdc++.h>
      
#define FOR(i,a,b) for( ll i = (a); i < (ll)(b); i++ )
#define REP(i,n) FOR(i,0,n)
#define YYS(x,arr) for(auto& x:arr)
#define ALL(x) (x).begin(),(x).end()
#define SORT(x) sort( (x).begin(),(x).end() )
#define REVERSE(x) reverse( (x).begin(),(x).end() )
#define UNIQUE(x) (x).erase( unique( ALL( (x) ) ) , (x).end() )
#define PW(x) (1LL<<(x))
#define SZ(x) ((ll)(x).size())
#define SHOW(x) cout << #x << " = " << x << endl

#define pb emplace_back
#define fi first
#define se second
     
using namespace std;

typedef long double ld;
typedef long long int ll;
typedef pair<int,int> pi;
typedef pair<ll,ll> pl;
typedef vector<int> vi;
typedef vector<ll> vl;
typedef vector<bool> vb;
typedef vector<ld> vd;
typedef vector<pi> vpi;
typedef vector<pl> vpl;
typedef vector<vpl> gr;
typedef vector<vl> ml;
typedef vector<vd> md;
typedef vector<vi> mi;
     
const ll INF = (ll)1e9 + 10;
const ll INFLL = (ll)1e18 + 10;
const ld EPS = 1e-12;
const ll MOD = 1e9+7;
     
template<class T> T &chmin( T &a , const T &b ){ return a = min(a,b); }
template<class T> T &chmax( T &a , const T &b ){ return a = max(a,b); }
template<class T> inline T sq( T a ){ return a * a; }

ll in(){ ll x; scanf( "%lld" , &x ); return x; }
char yuyushiki[1000010]; string stin(){ scanf( "%s" , yuyushiki ); return yuyushiki; }

// head

int n, a, b;
int d;

int x[100010], y[100010];

set<pi> sx, sy;
vpi vx, vy;

set<int> ss;

map<pi,int> mx, my;

void dfs( int v ){
  // SHOW( v );
  ss.insert( v );
  sx.erase( sx.find( pi( x[v] , y[v] ) ) );
  sy.erase( sy.find( pi( y[v] , x[v] ) ) );

  // left
  pi cur = pi( x[v] - d , y[v] - d );
  pi end = pi( x[v] - d , y[v] + d );
  while( 1 ){
    auto ite = sx.lower_bound( cur );
    if( ite == sx.end() or (*ite) > end ){
      break;
    }
    cur = *ite;
    dfs( mx[cur] );
  }
  
  // right
  cur = pi( x[v] + d , y[v] - d );
  end = pi( x[v] + d , y[v] + d );
  while( 1 ){
    auto ite = sx.lower_bound( cur );
    if( ite == sx.end() or (*ite) > end ){
      break;
    }
    cur = *ite;
    dfs( mx[cur] );
  }

  // up
  cur = pi( y[v] - d , x[v] - d );
  end = pi( y[v] - d , x[v] + d );
  while( 1 ){
    auto ite = sy.lower_bound( cur );
    if( ite == sy.end() or (*ite) > end ){
      break;
    }
    cur = *ite;
    dfs( my[cur] );
  }

  // down
  cur = pi( y[v] + d , x[v] - d );
  end = pi( y[v] + d , x[v] + d );
  while( 1 ){
    auto ite = sy.lower_bound( cur );
    if( ite == sy.end() or (*ite) > end ){
      break;
    }
    cur = *ite;
    dfs( my[cur] );
  }
}

int main(){

  n = in();
  a = in() - 1;
  b = in() - 1;

  REP( i , n ){
    int s = in();
    int t = in();
    x[i] = s + t;
    y[i] = s - t;
    pi px = pi( x[i] , y[i] );
    pi py = pi( y[i] , x[i] );
    mx[px] = i;
    my[py] = i;
    sx.insert( px );
    sy.insert( py );
  }

  d = max( abs( x[a] - x[b] ) , abs( y[a] - y[b] ) );
  
  dfs( a );

  REP( i , n ){
    pi px = pi( x[i] , y[i] );
    pi py = pi( y[i] , x[i] );
    vx.pb( px );
    vy.pb( py );
  }

  SORT( vx );
  SORT( vy );

  ll ans = 0;
  YYS( v , ss ){

    // left
    pi cur = pi( x[v] - d , y[v] - d );
    pi end = pi( x[v] - d , y[v] + d );
    ans += upper_bound( ALL(vx) , end ) - lower_bound( ALL(vx) , cur );

    // right
    cur = pi( x[v] + d , y[v] - d );
    end = pi( x[v] + d , y[v] + d );
    ans += upper_bound( ALL(vx) , end ) - lower_bound( ALL(vx) , cur );
    
    // up
    cur = pi( y[v] - d , x[v] - d );
    end = pi( y[v] - d , x[v] + d );
    ans += lower_bound( ALL(vy) , end ) - upper_bound( ALL(vy) , cur );

    // down
    cur = pi( y[v] + d , x[v] - d );
    end = pi( y[v] + d , x[v] + d );
    ans += lower_bound( ALL(vy) , end ) - upper_bound( ALL(vy) , cur );
  }

  cout << ans / 2 << endl;
  
  return 0;
}


Measured memory_bytes: 33908