#include <bits/stdc++.h>
#pragma GCC optimize("-O3")
using namespace std;
void _main();
int main() {
  cin.tie(0);
  ios::sync_with_stdio(false);
  _main();
}
const int inf = INT_MAX / 2;
const long long infl = 1LL << 60;
template <class T>
bool chmax(T &a, const T &b) {
  if (a < b) {
    a = b;
    return 1;
  }
  return 0;
}
template <class T>
bool chmin(T &a, const T &b) {
  if (b < a) {
    a = b;
    return 1;
  }
  return 0;
}
template <typename T>
struct Ruisekiwa {
  vector<T> v, sm;
  int nv;
  Ruisekiwa() {}
  Ruisekiwa(T *buf, int n) { init(buf, n); }
  void init(T *buf, int n) {
    nv = n;
    v = vector<T>(nv, 0);
    sm = vector<T>(nv, 0);
    for (int i = 0; i < nv; i++) v[i] = buf[i];
    sm[0] = v[0];
    for (int i = 1; i < nv; i++) sm[i] = sm[i - 1] + v[i];
  }
  T get(int l, int r) {
    if (l > r) return 0;
    T res = sm[r];
    if (l) res -= sm[l - 1];
    return res;
  }
  T getmin(int l, int r, T k) {
    if (l > r) return 0;
    if (v[l] <= k) return get(l, r);
    int great = l, less = r + 1;
    while (great + 1 != less) {
      int md = (less + great) / 2;
      if (v[md] <= k)
        less = md;
      else
        great = md;
    }
    T res = k * (great - l + 1);
    res += get(less, r);
    return res;
  }
  T query(int l, int r, T k) {
    if (l > r) return 0;
    if (v[l] - 1 <= k) return get(l, r) - (r - l + 1);
    int great = l, less = r + 1;
    while (great + 1 != less) {
      int md = (less + great) / 2;
      if (v[md] - 1 <= k)
        less = md;
      else
        great = md;
    }
    T res = k * (great - l + 1);
    res += get(less, r) - (r - less + 1);
    return res;
  }
};
int N;
long long A[501010];
Ruisekiwa<long long> rui;
pair<int, int> f(int k) {
  long long K = k + 1;
  if (rui.get(0, k) - K > K * (K - 1) + rui.getmin(k + 1, N - 1, K))
    return {10, -10};
  int ng = -1, ok = K;
  while (ng + 1 != ok) {
    int md = (ng + ok) / 2;
    if (rui.get(0, k) - md <= K * (K - 1) + rui.getmin(k + 1, N - 1, K))
      ok = md;
    else
      ng = md;
  }
  int L = ok;
  ok = 0, ng = N - k;
  while (ok + 1 != ng) {
    int md = (ok + ng) / 2;
    long long lft = rui.get(0, k) - K;
    long long rht = K * (K - 1) + rui.query(k + 1, k + 1 + md - 1, K) +
                    rui.getmin(k + 1 + md, N - 1, K);
    if (lft <= rht)
      ok = md;
    else
      ng = md;
  }
  int R = K + ok;
  return {L, R};
}
void _main() {
  cin >> N;
  for (int i = 0; i < N; i++) cin >> A[i];
  sort(A, A + N, greater<long long>());
  rui.init(A, N);
  int L = 0, R = N;
  for (int k = 0; k < N; k++) {
    int l, r;
    tie(l, r) = f(k);
    chmax(L, l);
    chmin(R, r);
  }
  long long tot = 0;
  for (int i = 0; i < N; i++) tot += A[i];
  vector<int> ans;
  for (int i = L; i < R + 1; i++)
    if (i % 2 == tot % 2) ans.push_back(i);
  int n = ans.size();
  if (n == 0) {
    printf("-1\n");
    return;
  }
  for (int i = 0; i < n; i++) {
    if (i) printf(" ");
    printf("%d", ans[i]);
  }
  printf("\n");
}
