#include <bits/stdc++.h>
using namespace std;
const double pi = acos(-1.0);
string NumberToString(long long Number) {
  stringstream ss;
  ss << Number;
  return ss.str();
}
long long StringToNumber(const string &Text) {
  stringstream ss(Text);
  long long result;
  return ss >> result ? result : 0;
}
void solve() {}
int main() {
  ios_base::sync_with_stdio(false);
  int na, nb;
  cin >> na >> nb;
  int k, m;
  cin >> k >> m;
  vector<int> a(na, -1);
  vector<int> b(nb, -1);
  for (int i = 0; i < na; i++) {
    cin >> a[i];
  }
  for (int i = 0; i < nb; i++) {
    cin >> b[i];
  }
  int f = a[k - 1];
  int s = b[nb - m];
  if (f < s) {
    cout << "YES" << endl;
  } else {
    cout << "NO" << endl;
  }
}
