#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, k, a[50];
  scanf("%d", &n);
  scanf("%d", &k);
  for (int i = 0; i < n; i++) scanf("%d", &a[i]);
  sort(a, a + n);
  if (k > n) {
    cout << -1 << endl;
    return 0;
  }
  if (n == k) {
    cout << 0 << " " << 0 << endl;
    return 0;
  }
  if (a[n - k - 1] < a[n - k])
    cout << a[n - k - 1] + 1 << " " << a[n - k - 1] + 1 << endl;
  else
    cout << -1 << endl;
  return 0;
}
