#include <bits/stdc++.h>
using namespace std;
void seif() { std::ios_base::sync_with_stdio(0); }
vector<pair<int, int>> vec;
int arr[200005];
int main() {
  seif();
  int n, a;
  cin >> n;
  for (int i = 0; i < n; ++i) {
    cin >> a;
    vec.push_back({a, i});
  }
  sort(vec.begin(), vec.end());
  int ptr = 0;
  for (pair<int, int> it : vec) {
    if (it.second > ptr)
      arr[it.second] = -1;
    else
      arr[it.second] = ptr - it.second - 1;
    ptr = max(ptr, it.second);
  }
  for (int i = 0; i < n; ++i) cout << arr[i] << ' ';
  return 0;
}
