#include <bits/stdc++.h>
using namespace std;
const long long int M = 2e5 + 10;
const long long int mod = 1e9 + 7;
const long long int infi = LLONG_MAX;
long long int ans, k, n, m, mymax = LLONG_MIN, mymin = LLONG_MAX, b, c, z, sum;
vector<long long int> v[M];
long long int visit[M], visit2[M];
long long int x[M], y[M], a[M];
long long int start_time[M], end_time[M], curr_time;
pair<long long int, long long int> next(long long int node) {
  long long int tempx = node + a[node], tempy = a[node];
  ;
  ;
  if (tempx > n || tempx <= 0) {
    return {-1, tempy};
  }
  tempy += a[tempx];
  tempx -= a[tempx];
  return {tempx, tempy};
}
long long int dfs(long long int node) {
  long long int tempx, tempy;
  visit[node] = 1;
  start_time[node] = curr_time++;
  pair<long long int, long long int> temp = next(node);
  tempx = temp.first;
  tempy = temp.second;
  if (tempx <= 0) {
    y[node] = tempy;
    end_time[node] = curr_time;
    return 0;
  };
  ;
  if (visit[tempx] != 1)
    dfs(tempx);
  else if (start_time[tempx] <= start_time[node] &&
           end_time[tempx] >= end_time[node]) {
    end_time[node] = curr_time;
    y[node] = -1;
    return 0;
  }
  end_time[node] = curr_time;
  if (y[tempx] == -1) {
    y[node] = -1;
    return 0;
  }
  tempy += y[tempx];
  y[node] = tempy;
  return 0;
}
int main() {
  long long int i, j;
  scanf("%lld", &n);
  for (i = 1; i < n; i++) scanf("%lld", &a[i + 1]), end_time[i] = mymin;
  for (i = 2; i < n + 1; i++) {
    if (visit[i] == 0) dfs(i);
  }
  visit[1] = 1;
  y[1] = -1;
  for (i = 1; i < n; i++) {
    long long int tempx = 1 + i - a[i + 1], tempy = i + a[i + 1];
    ;
    ;
    if (tempx <= 0 || tempx > n) {
      printf("%lld\n", tempy);
    } else if (y[tempx] != -1)
      printf("%lld\n", y[tempx] + tempy);
    else
      printf("%s", "-1\n");
  }
  return 0;
}
