#include <bits/stdc++.h>
using namespace std;
const int maxn = 5e5 + 10;
bool cmp(int x, int y) { return x > y; }
int n, d[maxn], a[maxn];
int chk(long long x) {
  if (x < 0) return -1;
  if (x >= n) return 1;
  for (int i = 1; i < n; i++) a[i] = d[i];
  a[n] = x;
  sort(a + 1, a + 1 + n, cmp);
  long long lsum = 0, rsum = 0;
  for (long long i = 1, j = n; i <= n; i++) {
    lsum += a[i];
    while (j > i && a[j] <= i) {
      rsum += a[j];
      j--;
    }
    if (j < i) rsum -= a[i];
    if (lsum > i * (i - 1) + rsum + max(j - i, (long long)0) * i) {
      if (a[i] <= x) return 1;
      return -1;
    }
  }
  return 0;
}
int main() {
  scanf("%d", &n), n++;
  int parity = 0;
  for (int i = 1; i < n; i++) scanf("%d", &d[i]), parity ^= d[i];
  parity &= 1;
  int l = 0, r = n / 2, L = -1, R = -1;
  while (l <= r) {
    int mid = (l + r) >> 1;
    int f = chk(mid * 2 + parity);
    if (f == -1)
      l = mid + 1;
    else
      r = mid - 1;
    if (!f) L = mid;
  }
  if (L == -1) {
    printf("-1");
    return 0;
  }
  l = L, r = n / 2;
  while (l <= r) {
    int mid = (l + r) >> 1;
    int f = chk(mid * 2 + parity);
    if (f == -1 || f == 1)
      r = mid - 1;
    else {
      l = mid + 1;
      R = mid;
    }
  }
  if (R == -1) {
    printf("-1");
    return 0;
  }
  for (int i = L; i <= R; i++) printf("%d ", i * 2 + parity);
  return 0;
}
