#include <bits/stdc++.h>
using namespace std;
int main() {
  long long int na, nb, k, m, max, min, temp;
  cin >> na >> nb >> k >> m;
  for (int i = 1; i <= na; i++) {
    cin >> temp;
    if (i == k) max = temp;
  }
  for (int i = 1; i <= nb; i++) {
    cin >> temp;
    if (i == nb - m + 1) min = temp;
  }
  if (min > max) {
    cout << "YES";
  } else {
    cout << "NO";
  }
  return 0;
}
