#include <bits/stdc++.h>
using namespace std;
int a[210000];
long long dp[210000][2];
int N;
long long solve(int index, int fw) {
  if (index <= 0 || index > N) return 0;
  if (index == 1) return -1;
  if (dp[index][fw] != -2) return dp[index][fw];
  dp[index][fw] = -1;
  int i2 = index;
  if (fw)
    i2 += a[index];
  else
    i2 -= a[index];
  long long r = solve(i2, (fw + 1) % 2);
  long long res;
  if (r == -1)
    res = -1;
  else
    res = a[index] + r;
  dp[index][fw] = res;
  return res;
}
int main() {
  for (int i = 0; i < 210000; i++)
    for (int j = 0; j < 2; j++) dp[i][j] = -2;
  scanf("%d", &N);
  for (int i = 0; i < N - 1; i++) cin >> a[i + 2];
  for (int i = 1; i < N; i++) {
    long long r = solve(1 + i, 0);
    if (r != -1) r += i;
    cout << r << endl;
  }
  return 0;
}
