#include <bits/stdc++.h>
using namespace std;
long long d[500000];
int n;
void printAns(int left, int right) {
  for (int i = left; i <= right; i += 2) {
    if (i > left) cout << " ";
    cout << i;
  }
  cout << "\n";
}
int works(int dx) {
  int big = n - 1;
  int small = 0;
  bool metlow = false;
  bool methigh = false;
  long long sum = 0;
  long long dsum = 0;
  for (int k = 1; k <= n + 1; k++) {
    int curd;
    if (!methigh && (big < 0 || d[big] <= dx)) {
      curd = dx;
      methigh = true;
    } else {
      curd = d[big--];
    }
    sum -= min(k - 1, curd);
    dsum += curd;
    while (small <= big && d[small] < k) small++;
    if (!metlow && !methigh && dx < k) {
      metlow = true;
    }
    sum += (big - small + 1);
    if (!metlow && !methigh) sum++;
    long long kk = k;
    if (dsum > kk * (kk - 1) + sum) {
      if (methigh)
        return 2;
      else
        return 1;
    }
  }
  return 0;
}
int findUpperBound(int left, int right) {
  while (left + 2 < right) {
    int mid = (left + right) / 2;
    if (left % 2 != mid % 2) mid++;
    if (works(mid) == 0)
      left = mid;
    else
      right = mid;
  }
  return left;
}
int findLowerBound(int left, int right) {
  while (left + 2 < right) {
    int mid = (left + right) / 2;
    if (left % 2 != mid % 2) mid++;
    if (works(mid) == 0)
      right = mid;
    else
      left = mid;
  }
  return right;
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  cin >> n;
  long long sum = 0;
  for (int i = 0; i < n; i++) {
    cin >> d[i];
    sum += d[i];
  }
  sort(d, d + n);
  int left = 0, right = n;
  if (sum % 2) {
    left = 1;
    if (right % 2 == 0) right--;
  } else {
    if (right % 2) right--;
  }
  if (left > right)
    cout << "-1\n";
  else if (works(left) == 0 && works(right) == 0)
    printAns(left, right);
  else if (works(left) == 0)
    printAns(left, findUpperBound(left, right));
  else if (works(right) == 0)
    printAns(findLowerBound(left, right), right);
  else {
    while (left + 2 < right) {
      int mid = (left + right) / 2;
      if (left % 2 != mid % 2) mid++;
      int code = works(mid);
      if (code == 0) {
        printAns(findLowerBound(left, mid), findUpperBound(mid, right));
        return 0;
      }
      if (code == 1)
        left = mid;
      else
        right = mid;
    }
    cout << "-1\n";
  }
  return 0;
}
