#include <bits/stdc++.h>
using namespace std;
int gin[200100], vis[200100][2], n;
long long gadd[200100][2];
void dfs(int v, int flg) {
  if (vis[v][flg]) {
    if (vis[v][flg] == 1) gadd[v][flg] = -1;
    return;
  }
  vis[v][flg] = 1;
  int tmp;
  if (flg) {
    tmp = v + gin[v];
    if (tmp > n) {
      gadd[v][flg] = gin[v];
      vis[v][flg] = 2;
      return;
    }
    dfs(tmp, !flg);
  } else {
    tmp = v - gin[v];
    if (tmp <= 0) {
      gadd[v][flg] = gin[v];
      vis[v][flg] = 2;
      return;
    }
    dfs(tmp, !flg);
  }
  vis[v][flg] = 2;
  if (gadd[tmp][!flg] < 0)
    gadd[v][flg] = -1;
  else
    gadd[v][flg] = gadd[tmp][!flg] + gin[v];
}
int main() {
  int i, j;
  gin[1] = 1;
  cin >> n;
  vis[1][1] = 1;
  gadd[1][1] = -1;
  for (i = 2; i <= n; i++) cin >> gin[i];
  for (i = 1; i < n; i++) {
    int tmp = i + 1;
    dfs(tmp, 0);
    if (gadd[tmp][0] < 0)
      puts("-1");
    else
      cout << (i + gadd[tmp][0]) << endl;
  }
}
