#include <bits/stdc++.h>
using namespace std;
int tree[4 * 200010];
int A[200010], ans[200010];
void update(int low, int high, int ind, int node) {
  if (low == high) {
    tree[node] = 1;
    return;
  }
  int mid = (low + high) / 2;
  if (ind <= mid)
    update(low, mid, ind, 2 * node);
  else
    update(mid + 1, high, ind, 2 * node + 1);
  tree[node] = tree[2 * node] + tree[2 * node + 1];
}
int query(int low, int high, int begin, int end, int node) {
  if (low > end || high < begin || begin > end) return 0;
  if (low >= begin && high <= end) {
    return tree[node];
  }
  int mid = (low + high) / 2;
  return query(low, mid, begin, end, 2 * node) +
         query(mid + 1, high, begin, end, 2 * node + 1);
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  int n;
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> A[i];
  }
  vector<pair<pair<int, int>, pair<int, pair<int, int> > > > qr;
  for (int i = 0; i < n; i++) {
    qr.push_back(make_pair(make_pair(A[i], 10000000),
                           make_pair(i, make_pair(100000000, 100000000))));
  }
  for (int i = 1; i <= n - 1; i++) {
    for (int j = 1; j <= n; j++) {
      int low = i * (j - 1) + 1;
      int high = i * j;
      int x = min(n - 1, high);
      if (low < n) {
        qr.push_back(make_pair(make_pair(A[j - 1], i),
                               make_pair(j - 1, make_pair(low, x))));
      }
      if (high >= n) break;
    }
  }
  sort(qr.begin(), qr.end());
  for (int i = 0; i < qr.size(); i++) {
    if (qr[i].first.second <= n - 1) {
      ans[qr[i].first.second] += query(0, n - 1, qr[i].second.second.first,
                                       qr[i].second.second.second, 1);
    } else {
      update(0, n - 1, qr[i].second.first, 1);
    }
  }
  for (int i = 1; i <= n - 1; i++) cout << ans[i] << " ";
  cout << '\n';
}
