#include<bits/stdc++.h>
using namespace std;
#define lli long long int
#define pb push_back
#define mp make_pair
#define pll pair<lli,lli>


int main(){
	int n, s, d;
	cin >> n >> s >> d;
	while(n--){
		int x, y;
		cin >> x >> y;
		if(x < s && y > d){
			cout << "Yes" ;
			return 0;
		}
	}
	cout << "No";
	return 0;
}

#include<bits/stdc++.h>
#include <iostream>
//#include <boost/math/common_factor.hpp>
using namespace std;

typedef long long ll;
typedef vector<ll> vi;
typedef vector<ll> vl;
typedef vector<pair<int, int> > vpii;
typedef vector<pair<ll, ll> > vpll;

#define all(x) x.begin(), x.end()
#define reg(i,x) for(ll i=0;i<x;i++)
#define regi(i,a,x) for(ll i=a;i<x;i++)
#define rev(i,n) for(ll i=n-1;i>0;i--)
#define pb push_back
#define lb lower_bound
#define ub upper_bound
#define watch(x) cout << (#x) << " is " << (x) << endl
#define FASTIO ios::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);
//const ll INF = 1e18;
const int INF = 1e9;
const int MOD = 1e9 + 7;
const int nax = 1000000 + 10;
ll gcd(ll a,ll b)
{
    if(b==0) return a;
    return gcd(b,a%b);
}
ll lcm(ll a,ll b)
{
    return (a*b)/gcd(a,b);
}
ll MAXN=1e9;
const int inf = (int)1e18;
const int N=(int)1e6+7;
#define print(a,b,c) cout<<a<<" "<<b<<" "<<c<<endl;
/*vi l(1e4+1);
vi adj[1e5+1];
bool vis[1e5+1];
int leader(int v)
{
    if(l[v]!=v) l[v]=leader(l[v]);
    return l[v];
}
int unite(int u,int v)
{
    int v1=leader(u);
    int v2=leader(v);
    l[v1]=v2;
}*/
/*bool sortbysec(const pair<ll,ll> &a,
              const pair<ll,ll> &b)
{
    return (a.second < b.second);
}*/
int fact(int n)
{
    // single line to find factorial
    return (n==1 || n==0) ? 1: n * fact(n - 1);
}

bool comp(pair<ll,ll> &a, pair<ll,ll> &b)
{
    return (2*a.first+a.second > 2*b.first+b.second);
}
/*bool check(ll n)
{
    for(ll i=3;i*i<=n;i+=2)
    {
        if(n%i==0) return true;
        if((n/i)%2!=0) return true;
    }
    return false;
}*/
int main()
{
    ll n,s,d;
    cin>>n>>s>>d;
    vpll v(n);
    bool ans=false;
    reg(i,n)
    {
        int x,y;
        cin>>x>>y;
        if(x<s && y>d) ans=true;
    }
    if(ans) cout<<"Yes"<<endl;
    else cout<<"No"<<endl;
}
