#include <bits/stdc++.h>
using namespace std;
int main() {
  std::ios::sync_with_stdio(false);
  long long x, y, i, j;
  while (cin >> x) {
    vector<long long> v;
    v.clear();
    for (i = 0; i < 2 * x; i++) {
      cin >> y;
      v.push_back(y);
    }
    sort(v.begin(), v.end());
    long long sum_n1 = 0, sum_n2 = 0;
    for (i = 0; i < 2 * x; i++) {
      if (i < x) {
        sum_n1 += v[i];
      }
      if (i >= x) {
        sum_n2 += v[i];
      }
    }
    if (sum_n1 != sum_n2) {
      for (i = 0; i < 2 * x; i++) {
        cout << v[i] << " ";
      }
      cout << endl;
    } else {
      cout << "-1" << endl;
    }
  }
}
