#include <bits/stdc++.h>
using namespace std;
const int N = 3e5 + 100;
int a[N];
int ans[N];
int main() {
  int n;
  scanf("%d", &n);
  int minValue = 2e9;
  int maxValue = -1;
  for (int i = 0; i < n; i++) {
    scanf("%d", &a[i]);
    a[i + n] = a[i + n + n] = a[i];
    minValue = min(minValue, a[i]);
    maxValue = max(maxValue, a[i]);
  }
  if (minValue * 2 >= maxValue) {
    for (int i = 0; i < n; i++) {
      printf("-1 ");
    }
    printf("\n");
    return 0;
  }
  int curMax = a[n - 1];
  for (int i = n; i < 3 * n; i++) {
    if (2 * a[i] < curMax) {
      ans[n - 1] = i - n + 1;
      break;
    }
    curMax = max(curMax, a[i]);
  }
  vector<pair<int, int> > vec;
  for (int i = 3 * n - 1; i >= n - 1; i--) {
    while (!vec.empty() && vec.back().first >= a[i]) {
      vec.pop_back();
    }
    vec.push_back(make_pair(a[i], i));
  }
  for (int i = n - 2; i >= 0; i--) {
    ans[i] = ans[i + 1] + 1;
    int pos =
        lower_bound(vec.begin(), vec.end(), make_pair((a[i] + 1) / 2, i)) -
        vec.begin();
    if (pos != 0) {
      pos--;
      ans[i] = min(ans[i], vec[pos].second - i);
    }
    while (!vec.empty() && vec.back().first >= a[i]) {
      vec.pop_back();
    }
    vec.push_back(make_pair(a[i], i));
  }
  for (int i = 0; i < n; i++) {
    printf("%d ", ans[i]);
  }
  printf("\n");
  return 0;
}
