#include <bits/stdc++.h>
using namespace std;
long long a[200002];
bool vist[200002][2] = {};
int dp[200002][2];
long long dp_[200002][2];
int n;
int last(int i, bool ar) {
  if (dp[i][ar] != -1) return dp[i][ar];
  if (i == 1 and ar) return dp[i][ar] = 0;
  if (i == 1 and !ar) return dp[i][ar] = 1;
  if (vist[i][ar]) return dp[i][ar] = 0;
  vist[i][ar] = 1;
  if (ar) {
    if (i + a[i] <= n)
      return dp[i][ar] = last(i + a[i], !ar);
    else
      return dp[i][ar] = i;
  } else {
    if (i - a[i] > 0)
      return dp[i][ar] = last(i - a[i], !ar);
    else
      return dp[i][ar] = i;
  }
}
long long f(int i, int ar) {
  if (dp_[i][ar] != -1) return dp_[i][ar];
  if (ar) {
    if (i + a[i] <= n)
      return dp_[i][ar] = a[i] + f(i + a[i], !ar);
    else
      return dp_[i][ar] = a[i];
  } else {
    if (i - a[i] > 1)
      return dp_[i][ar] = a[i] + f(i - a[i], !ar);
    else
      return dp_[i][ar] = a[i];
  }
}
int main(int argc, char const *argv[]) {
  cin >> n;
  memset(dp, -1, sizeof dp);
  memset(dp_, -1, sizeof dp_);
  for (int i = 2; i <= n; ++i) {
    cin >> a[i];
  }
  for (int i = 1; i <= n - 1; ++i) {
    if (last(i + 1, 0) > 0) {
      if (last(i + 1, 0) == 1)
        cout << f(i + 1, 0) + 2 * i << endl;
      else
        cout << f(i + 1, 0) + i << endl;
    } else
      cout << -1 << endl;
  }
  return 0;
}
