#include <bits/stdc++.h>
using namespace std;
int main() {
  long long t = 1;
  while (t--) {
    long long n1, n2;
    cin >> n1 >> n2;
    long long k, m;
    cin >> k >> m;
    long long arr[n1];
    long long arr1[n2];
    for (int i = 0; i < n1; i++) cin >> arr[i];
    for (int i = 0; i < n2; i++) cin >> arr1[i];
    if (arr[k - 1] < arr1[n2 - m])
      cout << "YES" << endl;
    else
      cout << "NO" << endl;
  }
  return 0;
}
