#include <bits/stdc++.h>
using namespace std;
#define rep(i,n) for (int i = 0; i < (n); i++)
using ll = long long;
using P = pair<int,int>;
int main()
{
    int n, s, d;
    cin >> n >> s >> d;

    rep(i, n){
        int x, y;
        cin >> x >> y;
        if(x < s && y > d){
            cout << "Yes" << endl;
            return 0;
        }
    }

    cout << "No" << endl;
return 0;
}
#include<bits/stdc++.h>

using namespace std;





int main(){


     int a,b,c;
     cin>>a>>b>>c;
     if(a!=b && a==c){
          cout<<b<<endl;
     }
     else if(a==b && a==c){
          cout<<a<<endl;
     }else if(a!=b && b!= c){
          cout<<0<<endl;
     }
     else if(a!=b && a!=c){
          cout<<a<<endl;
     }else{
          cout<<c<<endl;
     }
}