#include <bits/stdc++.h>
using namespace std;
bool visited[200000];
long long mem[200000];
int a[200000];
int n;
long long run23(int x) {
  if (visited[x]) return mem[x];
  visited[x] = true;
  long long dy = a[x];
  int newx = x + a[x];
  if (newx >= n) {
    mem[x] = dy;
    return dy;
  }
  dy += a[newx];
  newx -= a[newx];
  if (newx < 0) {
    mem[x] = dy;
    return dy;
  }
  long long r = run23(newx);
  if (r == -1)
    mem[x] = -1;
  else
    mem[x] = r + dy;
  return mem[x];
}
int main() {
  cin >> n;
  for (int i = 1; i < n; i++) {
    visited[i] = false;
    mem[i] = -1;
    cin >> a[i];
  }
  visited[0] = true;
  mem[0] = -1;
  for (int i = 1; i < n; i++) {
    int x = i - a[i];
    long long dy;
    if (x < 0)
      cout << i + a[i] << endl;
    else if ((dy = run23(x)) == -1)
      cout << "-1" << endl;
    else
      cout << i + a[i] + dy << endl;
  }
}
