#include <bits/stdc++.h>
using namespace std;
const int MAXN = 300100;
int a[MAXN];
int ans[MAXN], n;
int anc(int x, int k) {
  if (x % k == 0) {
    return x / k - 1;
  } else {
    return x / k;
  }
}
int add[MAXN];
int main() {
  scanf("%d", &n);
  for (int i = 0; i < n; i++) {
    scanf("%d", &a[i]);
    if (i > 0) {
      ans[1] += (a[i] < a[i - 1]);
    }
  }
  for (int i = 1; i < n; i++) {
    int cur = 2;
    int pr = anc(i, 2);
    while (true) {
      int val = (a[pr] > a[i]);
      add[cur] += val;
      if (pr == 0) {
        break;
      }
      int nxt = i / pr;
      nxt = max(nxt - 1, cur);
      while (anc(i, nxt) == pr) {
        nxt++;
      }
      add[nxt] -= val;
      pr = anc(i, nxt);
      cur = nxt;
    }
  }
  printf("%d ", ans[1]);
  int bal = 0;
  for (int i = 2; i < n; i++) {
    bal += add[i];
    printf("%d ", bal);
  }
  printf("\n");
  return 0;
}
