#include <bits/stdc++.h>
long long dp[200005][2];
long long a[200005];
int vis[200005][2];
int n;
int cyc[200005][2];
int color[200005][2];
long long back(long long pos, int d) {
  if (pos <= 0 || pos > n) return 0;
  if (vis[pos][d]) return dp[pos][d];
  vis[pos][d] = true;
  dp[pos][d] = 0;
  color[pos][d] = 1;
  if (pos == 1) {
    dp[pos][d] = -1;
    color[pos][d] = 2;
    return -1;
  }
  if (d == 0) {
    long long nxt = pos + a[pos];
    if (nxt > n)
      dp[pos][d] = a[pos];
    else {
      if (vis[nxt][1]) {
        if (color[nxt][1] == 1)
          dp[pos][d] = -1;
        else {
          long long ret = back(pos + a[pos], 1);
          if (ret == -1)
            dp[pos][d] = -1;
          else
            dp[pos][d] = a[pos] + ret;
        }
      } else {
        long long ret = back(pos + a[pos], 1);
        if (ret == -1)
          dp[pos][d] = -1;
        else
          dp[pos][d] = a[pos] + ret;
      }
    }
  } else {
    long long nxt = pos - a[pos];
    if (nxt < 0)
      dp[pos][d] = a[pos] + back(nxt, 0);
    else {
      if (vis[nxt][0]) {
        if (color[nxt][0] == 1)
          dp[pos][d] = -1;
        else {
          if (dp[nxt][0] != -1)
            dp[pos][d] = a[pos] + dp[nxt][0];
          else
            dp[pos][d] = -1;
        }
      } else {
        if (back(nxt, 0) == -1)
          dp[pos][d] = -1;
        else
          dp[pos][d] = a[pos] + back(nxt, 0);
      }
    }
  }
  color[pos][d] = 2;
  return dp[pos][d];
}
int main() {
  scanf("%d", &n);
  for (int i = 2; i <= n; i++) scanf("%I64d", &a[i]);
  for (int i = 2; i <= n; i++) {
    back(i, 0), back(i, 1);
  }
  for (int i = 1; i <= n - 1; i++) {
    long long ret = back(1 + i, 1);
    if (ret != -1)
      printf("%I64d\n", i + ret);
    else
      printf("-1\n");
  }
  return 0;
}
