#include <bits/stdc++.h>
using namespace std;
int a[300005], d[300005][20];
int Log[300005];
int f[300005];
int n;
int query(int x, int y) {
  int k = Log[y - x + 1];
  return max(d[x][k], d[y - (1 << k) + 1][k]);
}
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
  for (int i = 1; i <= n; i++) a[n + i] = a[2 * n + i] = a[i];
  int N = 3 * n;
  Log[1] = 0;
  for (int i = 2; i <= N; i++) Log[i] = Log[i >> 1] + 1;
  for (int i = 1; i <= N; i++) d[i][0] = (a[i] + 1) / 2 - 1;
  for (int j = 1; j <= Log[N]; j++) {
    for (int i = 1; i + (1 << j) - 1 <= N; i++)
      d[i][j] = max(d[i][j - 1], d[i + (1 << (j - 1))][j - 1]);
  }
  for (int i = 1; i <= N; i++) f[i] = 0x3f3f3f3f;
  for (int i = 1; i <= N; i++) {
    if (i == 1) continue;
    int l = 1, r = i - 1;
    while (l <= r) {
      int mid = (l + r) >> 1;
      if (query(mid, i - 1) >= a[i])
        l = mid + 1;
      else
        r = mid - 1;
    }
    if (r == 0) continue;
    f[r] = min(f[r], i);
  }
  f[N + 1] = 0x3f3f3f3f;
  for (int i = N; i >= 1; i--) f[i] = min(f[i + 1], f[i]);
  for (int i = 1; i <= n; i++)
    if (f[i] == 0x3f3f3f3f)
      printf("-1 ");
    else
      printf("%d ", f[i] - i);
  puts("");
  return 0;
}
