#include <bits/stdc++.h>
using namespace std;
const int MAXN = 400000;
int n;
int v[MAXN], add[MAXN];
int main() {
  cin >> n;
  for (int i = 0; i < n; ++i) {
    scanf("%d", v + i);
  }
  for (int i = 1; i < n; ++i) {
    for (int j = 1, nxt; j < n; j = nxt) {
      int X = i - 1;
      int curQ = X / j;
      if (curQ == 0) {
        nxt = n;
      } else if (curQ == 1) {
        nxt = X + 1;
      } else {
        nxt = max(X / curQ, j);
        for (; nxt < n && X / nxt == curQ; ++nxt)
          ;
      }
      if (v[curQ] > v[i]) {
        ++add[j];
        --add[nxt];
      }
    }
  }
  for (int i = 1, acc = 0; i < n; ++i) {
    acc += add[i];
    printf("%d%c", acc, " \n"[i + 1 == n]);
  }
  return 0;
}
