#include <bits/stdc++.h>
using namespace std;
const int maxn = 200005;
long long a[maxn], mem[maxn];
int pos = 1;
int used[maxn];
long long n;
void read() {
  scanf("%lld", &n);
  for (int i = 2; i <= n; ++i) scanf("%lld", &a[i]);
}
long long go(long long k) {
  if (used[k] == pos) {
    mem[k] = -1;
    return -1;
  }
  if (mem[k] != 0) return mem[k];
  if (k <= 0LL || k > n) return 0;
  used[k] = pos;
  long long ret = 0LL;
  long long p = k;
  ret += a[p];
  p += a[p];
  if (p > n) {
    mem[k] = ret;
    return ret;
  }
  long long tmp;
  ret += a[p];
  p -= a[p];
  if (p <= 0 || p > n) {
    mem[k] = ret;
    return ret;
  } else {
    tmp = go(p);
    if (tmp != -1) {
      mem[k] = ret + tmp;
      return mem[k];
    } else {
      mem[k] = -1;
      return -1;
    }
  }
}
void solve() {
  for (long long i = 2; i <= n; ++i) {
    used[1] = 1;
    if (mem[i] == 0) go(i);
    ++pos;
  }
  mem[1] = -1;
  long long x = 1LL, y = 0LL, p;
  for (long long i = 1; i < n; ++i) {
    a[1] = i;
    x = 1LL;
    y = 0LL;
    p = x;
    y += a[p];
    p += a[p];
    if (p > n) {
      printf("%I64d\n", y);
    } else {
      y += a[p];
      p -= a[p];
      if (p <= 0 || p > n) {
        printf("%I64d\n", y);
      } else {
        if (mem[p] != -1)
          printf("%I64d\n", (long long)(y + mem[p]));
        else
          printf("-1\n");
      }
    }
  }
}
int main() {
  read();
  solve();
  return 0;
}
