#include <bits/stdc++.h>
using namespace std;
int32_t main() {
  long long n;
  cin >> n;
  vector<long long> vec(2 * n);
  for (long long i = 0; i < 2 * n; i++) {
    cin >> vec[i];
  }
  sort(vec.begin(), vec.end());
  if (accumulate(vec.begin(), vec.begin() + n, 0) ==
      accumulate(vec.begin() + n, vec.end(), 0)) {
    cout << -1 << endl;
  } else {
    for (long long a : vec) {
      cout << a << " ";
    }
    cout << endl;
  }
}
