#include <bits/stdc++.h>
using namespace std;
const int N = 1000025, p = 998244353, inf = 0x3f3f3f3f;
int read() {
  int f = 1, g = 0;
  char ch = getchar();
  for (; !isdigit(ch); ch = getchar())
    if (ch == '-') f = -1;
  for (; isdigit(ch); ch = getchar()) g = g * 10 + ch - '0';
  return f * g;
}
int n, m, a[N], b[N], c[N], s, ansl, ansr;
int check(int x) {
  if (x < 0) return 0;
  int i, j = n + 1, ans = 0;
  for (i = 1; (i <= n) && (a[i] > x); i++) b[i] = a[i];
  b[i] = x;
  for (; i <= n; i++) b[i + 1] = a[i];
  long long sum = 0, t = 0;
  for (int i = 1; i <= n + 1; i++) {
    while ((j > i) && (b[j] < i)) t += b[j--];
    while (j < i) t -= b[++j];
    sum += b[i];
    if (sum > (long long)i * (i - 1) + t + (long long)(j - i) * i) {
      if (a[i] >= x)
        ans = -1;
      else
        ans = 1;
      break;
    }
  }
  return ans;
}
int lower_b(int l, int r) {
  while (l < r) {
    int mid = (l + r) >> 1;
    if (check(c[mid]) >= 0)
      r = mid;
    else
      l = mid + 1;
  }
  return l;
}
int upper_b(int l, int r) {
  while (l < r) {
    int mid = (l + r) >> 1;
    if (check(c[mid]) > 0)
      r = mid;
    else
      l = mid + 1;
  }
  return l;
}
int main() {
  n = read();
  for (int i = 1; i <= n; i++) {
    a[i] = read();
    s ^= (a[i] & 1);
  }
  sort(a + 1, a + n + 1);
  reverse(a + 1, a + n + 1);
  for (; s <= n; s += 2) c[++m] = s;
  ansl = lower_b(1, m + 1);
  ansr = upper_b(1, m + 1);
  if (ansl >= ansr)
    puts("-1");
  else {
    for (int i = ansl; i < ansr; i++) printf("%d ", c[i]);
    printf("\n");
  }
  return 0;
}
