#include <bits/stdc++.h>
using namespace std;
int main() {
  int i, n, S1 = 0, S2 = 0, t, flag = 0;
  cin >> n;
  int A[2 * n];
  for (i = 0; i < 2 * n; i++) cin >> A[i];
  sort(A, A + (2 * n));
  for (i = 0; i < n; i++) S1 += A[i];
  for (i = n; i < 2 * n; i++) S2 += A[i];
  if (S1 == S2) {
    cout << "-1";
    return 0;
  } else {
    for (i = 0; i < 2 * n; i++) cout << A[i] << " ";
  }
}
