#include #define For(i, a, n) for(ll i = a; i < (n); i++) #define rep(i, n) for(ll i = 0; i < (n); i++) #define dep(i, n) for(ll i = n - 1; i >= 0; i--) #define all(x) x.begin(), x.end() #define maxs(a, b) (a = max(a, b)) #define mins(a, b) (a = min(a, b)) using namespace std; using ll = long long; using vi = vector; using vl = vector; using vll = vector; using vii = vector; using vvl = vector; using vvll = vector; const ll INF = 1LL << 60; const double PI = acos(-1.0); template T vgcd(T m, T n){ return gcd(m, n); } template T vgcd(T a, Args... args){ return vgcd(a, vgcd(args...)); } int main(void) { int a, b, c, d; cin >> a >> b >> c >> d; cout << (a < b && c > d ? "YES" : "NO") << endl; return 0; }