#include <bits/stdc++.h>
using namespace std;
long long arr[1000001], read[200001], total[200001];
int main() {
  long long n, s1 = 0, s2 = 0;
  cin >> n;
  for (int i = 0; i < 2 * n; i++) {
    cin >> arr[i];
  }
  sort(arr, arr + 2 * n);
  for (int i = 0; i < n; i++) {
    s1 += arr[i];
  }
  for (int i = n; i < 2 * n; i++) {
    s2 += arr[i];
  }
  if (s1 == s2)
    cout << "-1" << endl;
  else {
    for (int i = 0; i < 2 * n; i++) {
      cout << arr[i] << " ";
    }
  }
}
