#include <bits/stdc++.h>
using namespace std;
template <typename T>
void _dbg(const char* _s, T _h) {
  cerr << _s << " = " << _h << "\n";
}
template <typename T, typename... Ts>
void _dbg(const char* _s, T _h, Ts... _t) {
  int _b = 0;
  while (((_b += *_s == '(') -= *_s == ')') != 0 || *_s != ',') cerr << *_s++;
  cerr << " = " << _h << ",";
  _dbg(_s + 1, _t...);
}
const int64_t INF = static_cast<int64_t>(1e9) + 7;
const int64_t LINF = INF * INF;
const int MAXN = static_cast<int>(1e6) + 17;
void solve() {
  int n;
  cin >> n;
  vector<int64_t> vec(3 * n);
  int64_t mn = INF, mx = 0;
  for (int i = 0; i < n; ++i) {
    cin >> vec[i];
    mx = max(mx, vec[i]);
    mn = min(mn, vec[i]);
    vec[i + 2 * n] = vec[i + n] = vec[i];
  }
  if (2 * mn >= mx) {
    for (int i = 0; i < n; ++i) {
      cout << "-1 ";
    }
    cout << '\n';
    return;
  }
  vector<int> ans(3 * n, -1);
  vector<int> st_max, st_min;
  for (int i = 3 * n - 1; i >= 0; --i) {
    while (!st_max.empty() && vec[st_max.back()] < vec[i]) {
      st_max.pop_back();
    }
    while (!st_min.empty() && vec[st_min.back()] > vec[i]) {
      st_min.pop_back();
    }
    int left = -1, right = st_min.size();
    while (right - left > 1) {
      int mid = (left + right) / 2;
      if (vec[st_min[mid]] * 2 < vec[i]) {
        left = mid;
      } else {
        right = mid;
      }
    }
    int nxt = 3 * n;
    if (left != -1) {
      nxt = min(nxt, st_min[left]);
    }
    if (!st_max.empty()) {
      nxt = min(nxt, st_max.back());
    }
    if (nxt < 3 * n && vec[nxt] >= vec[i]) {
      ans[i] = ans[nxt];
    } else {
      ans[i] = nxt;
    }
    st_min.push_back(i);
    st_max.push_back(i);
  }
  for (int i = 0; i < n; i++) {
    cout << (ans[i] == 3 * n ? -1 : ans[i] - i) << ' ';
  }
  cout << '\n';
}
int main() {
  cin.tie(nullptr);
  cout.tie(nullptr);
  ios_base::sync_with_stdio(false);
  int q = 1;
  for (int i = 0; i < q; ++i) {
    solve();
  }
}
