#include <bits/stdc++.h>
using namespace std;
int tr[1000005];
int n;
void add(int x) {
  tr[x + n]++;
  for (int v = (x + n) >> 1; v > 0; v >>= 1)
    tr[v] = tr[v << 1] + tr[(v << 1) + 1];
}
int getSum(int l, int r) {
  int ans = 0;
  for (int vl = (l + n), vr = (r + n); vl <= vr;
       vl = (vl + 1) / 2, vr = (vr - 1) / 2) {
    if (vl & 1) ans += tr[vl];
    if (!(vr & 1)) ans += tr[vr];
  }
  return ans;
}
int a[200005];
int ans[200005];
pair<int, int> ve[200005];
int main() {
  int nn;
  scanf("%d", &nn);
  for (int i = 0; i < nn; i++) scanf("%d", &a[i]), ve[i] = make_pair(a[i], i);
  sort(ve, ve + nn);
  n = 1;
  while (n <= nn) n <<= 1;
  for (int i = 0; i < nn; i++) {
    int id = ve[i].second + 1;
    for (int k = 1; k * (id - 1) + 2 <= nn && k < nn; k++) {
      ans[k] += getSum(k * (id - 1) + 2, min(k * id + 1, nn));
    }
    add(id);
  }
  for (int i = 1; i < nn; i++) printf("%d ", ans[i]);
  printf("\n");
  return 0;
}
