#include <bits/stdc++.h>
using namespace std;
int as[111111], ms[111111];
int main() {
  int n;
  cin >> n;
  for (int i = 0; i < int(n); ++i) cin >> as[i];
  int m = 1 << 30;
  for (int i = n - 1; i >= 0; --i) m = min(m, as[i]), ms[i] = m;
  for (int i = 0; i < int(n); ++i) {
    int ans = upper_bound(ms, ms + n, as[i] - 1) - (ms + i) - 2;
    if (ans < 0) ans = -1;
    cout << ans << (i == n - 1 ? '\n' : ' ');
  }
}
