#include <bits/stdc++.h>
using namespace std;
int main() {
  int n1, n2, k, m, i, a[101000], b[101000], j;
  while (scanf("%d%d", &n1, &n2) != EOF) {
    scanf("%d%d", &k, &m);
    for (i = 0; i < n1; i++) scanf("%d", &a[i]);
    for (j = 0; j < n2; j++) scanf("%d", &b[j]);
    if (a[k - 1] < b[n2 - m])
      printf("YES\n");
    else
      printf("NO\n");
  }
  return 0;
}
