#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  int arr[2 * n];
  for (int i = 0; i < 2 * n; i++) {
    cin >> arr[i];
  }
  sort(arr, arr + (2 * n));
  int sum = 0;
  int d = 0, f = 0;
  for (int i = 0; i < n; i++) {
    d += arr[i];
  }
  for (int i = n; i < 2 * n; i++) {
    f += arr[i];
  }
  if (d == f) {
    cout << -1 << endl;
  } else {
    for (int i = 0; i < 2 * n; i++) {
      cout << arr[i] << " ";
    }
  }
  return 0;
}
