#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, k, a;
  vector<int> vec;
  cin >> n >> k;
  if (k > n) {
    cout << "-1" << endl;
    return 0;
  }
  for (int i = 0; i < n; i++) {
    cin >> a;
    vec.push_back(a);
  }
  sort(vec.begin(), vec.end());
  reverse(vec.begin(), vec.end());
  for (int i = 0; i < vec.size(); i++)
    if (i + 1 == k)
      cout << vec[i] << " "
           << "0" << endl;
  return 0;
}
