#include <bits/stdc++.h>
using namespace std;
int i;
int main() {
  int n, k;
  cin >> n >> k;
  int l, m;
  int f, a[n];
  for (i = 0; i < n; i++) {
    cin >> a[i];
  }
  sort(a, a + n);
  if (k > n)
    cout << -1;
  else if (n == k)
    cout << a[0] << " " << a[0];
  else
    cout << a[n - k - 1] << " " << a[n - k - 1] + 1;
}
