#include <iostream>
#include<vector>
#include<string>
#include<algorithm>
#include<iomanip>
#include<map>
#include<complex>
#include<functional>
#include<stack>
#include<queue>
#include<set>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define req(i,n) for(int i = 1;i <=  n; i++)
#define rrep(i,n) for(ll i = n-1;i >= 0;i--)
#define ALL(obj) begin(obj), end(obj)
#define RALL(a) rbegin(a),rend(a)
typedef long long ll;
typedef long double ld;
template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return 1; } return 0; }
template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return 1; } return 0; }
const ll INF = 1e18;
ll mod = 1e9 + 7;
int main() {
    int n, d, s,x,y; cin >> n >> s >> d;
    bool ok = 0;
    rep(i, n) {
        cin >> x >> y;
        if (x<s && y>d)ok = 1;
    }if (ok)cout << "Yes" << endl;
    else cout << "No" << endl;
}
#include <bits/stdc++.h>
using namespace std;
#define ios ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);
#define lop ios; ll t; cin>>t; while(t--)
#define pb push_back
#define vi vector<ll>
#define vivi vector<vector<ll>> 
#define vipa vector<pair<ll,ll>>
#define F first
#define S second
#define M 1000000007
#define kl "\n"
#define all(v) v.begin(),v.end()
typedef long long ll;
ll lcm(ll x, ll y){ll k=x*y; k/=(__gcd(x,y)); return k;}
ll power(ll x,ll y){ ll r= 1;x = x % M;if(x==0) return 0; while(y>0) {if(y&1) r=(r*x)%M; y=y>>1; x=(x*x)%M;} return r;}  

void solve()
{
    ll n,s,d;
    cin>>n>>s>>d;
    for(ll i=0;i<n;i++){
        ll a,b;
        cin>>a>>b;
        if(a < s and b > d){
            cout<<"Yes";
            return;
        }
    }
    cout<<"No";
}
int main() 
{ 
    
    // lop
    solve();
	return 0; 
} 


