#include <bits/stdc++.h>
using namespace std;
const int M = 2001;
int n, s, m, k;
int A[M], B[M], sum[M];
struct Segment {
  int L, R;
  void in() { scanf("%d%d", &L, &R); }
  Segment() {}
  Segment(int a, int b) : L(a), R(b) {}
} S[M];
int nex[M], dp[M][M];
bool check(int kth) {
  for (int i = 1; i <= n; i++) sum[i] = (sum[i - 1] + (A[i] <= kth));
  for (int i = 0; i <= m; i++)
    for (int j = 0; j <= n; j++) dp[i][j] = 0;
  for (int i = 1; i <= m; i++) {
    for (int j = 1; j <= n; j++) dp[i][j] = max(dp[i][j], dp[i - 1][j]);
    for (int j = 1; j <= n; j++)
      if (nex[j]) {
        dp[i][nex[j]] =
            max(dp[i][nex[j]], dp[i - 1][j - 1] + sum[nex[j]] - sum[j - 1]);
      }
    for (int j = 1; j <= n; j++) dp[i][j] = max(dp[i][j], dp[i][j - 1]);
  }
  return dp[m][n] >= k;
}
int main() {
  scanf("%d%d%d%d", &n, &s, &m, &k);
  for (int i = 1; i <= n; i++) scanf("%d", &A[i]), B[i] = A[i];
  sort(B + 1, B + n + 1);
  for (int i = 1; i <= s; i++) {
    S[i].in();
    for (int j = S[i].L; j <= S[i].R; j++) {
      nex[j] = max(nex[j], S[i].R);
    }
  }
  int l = 1, r = n, mid, ans = -1;
  while (l <= r) {
    mid = l + r >> 1;
    if (check(B[mid]))
      ans = B[mid], r = mid - 1;
    else
      l = mid + 1;
  }
  printf("%d\n", ans);
  return 0;
}
