#include <bits/stdc++.h>
using namespace std;
const int SZ = 1 << 19;
int tree[2 * SZ], A[100000], P[300000];
vector<int> x;
void set_tree(int n, int v) {
  for (tree[n += SZ] = v; n >>= 1;) tree[n] = max(tree[2 * n], tree[2 * n + 1]);
}
int get_max(int s, int e) {
  int ret = -1;
  for (s += SZ, e += SZ; s <= e; s >>= 1, e >>= 1) {
    if (s & 1) ret = max(ret, tree[s++]);
    if (~e & 1) ret = max(ret, tree[e--]);
  }
  return ret;
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  ((void)0);
  ((void)0);
  ((void)0);
  int N;
  cin >> N;
  x.resize(N);
  for (int i = 0; i < N; i++) {
    cin >> A[i];
    x[i] = A[i];
  }
  sort(x.begin(), x.end());
  x.resize(unique(x.begin(), x.end()) - x.begin());
  if (2 * x[0] >= x.back()) {
    for (int i = 0; i < N; i++) cout << "-1 ";
    return 0;
  }
  memset(tree, -1, sizeof(tree));
  for (int i = 0; i < N; i++) {
    A[i] = lower_bound(x.begin(), x.end(), A[i]) - x.begin();
    P[i] = get_max(upper_bound(x.begin(), x.end(), 2 * x[A[i]]) - x.begin(),
                   SZ - 1);
    set_tree(A[i], i);
  }
  for (int i = 0; i < N; i++) {
    P[i + N] = get_max(upper_bound(x.begin(), x.end(), 2 * x[A[i]]) - x.begin(),
                       SZ - 1);
    set_tree(A[i], i + N);
  }
  for (int i = 0; i < N; i++) {
    P[i + 2 * N] = get_max(
        upper_bound(x.begin(), x.end(), 2 * x[A[i]]) - x.begin(), SZ - 1);
    set_tree(A[i], i + 2 * N);
  }
  for (int i = 0; i < 3 * N; i++) tree[SZ + i] = P[i];
  for (int i = SZ; --i;) tree[i] = max(tree[2 * i], tree[2 * i + 1]);
  for (int i = 0; i < N; i++) {
    int ans = 0, s = i, e = 3 * N - 1;
    while (s <= e) {
      int m = (s + e) >> 1;
      if (get_max(i, m) >= i)
        e = m - 1;
      else
        s = m + 1;
    }
    ans = s - i;
    s = i + N;
    e = 3 * N - 1;
    while (s <= e) {
      int m = (s + e) >> 1;
      if (get_max(i + N, m) >= i + N)
        e = m - 1;
      else
        s = m + 1;
    }
    ans = max(ans, s - i - N);
    s = i + 2 * N;
    e = 3 * N - 1;
    while (s <= e) {
      int m = (s + e) >> 1;
      if (get_max(i + 2 * N, m) >= i + 2 * N)
        e = m - 1;
      else
        s = m + 1;
    }
    cout << max(ans, s - i - 2 * N) << ' ';
  }
  return 0;
}
