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