#include <bits/stdc++.h>
using namespace std;
int n, i, node, p, k;
int a[200000 + 5], sol[200000 + 5];
int main() {
  scanf("%d", &n);
  for (i = 0; i < n; ++i) scanf("%d", &a[i]);
  for (node = 1; node < n; ++node) {
    k = 1;
    p = (node - 1) / k;
    while (p > 0) {
      if (a[p] > a[node]) ++sol[k];
      k = (node - 1) / p + 1;
      if (a[p] > a[node]) --sol[k];
      p = (node - 1) / k;
    }
    if (a[0] > a[node]) ++sol[node];
  }
  for (i = 1; i < n; ++i) {
    sol[i] += sol[i - 1];
    printf("%d ", sol[i]);
  }
  printf("\n");
  return 0;
}
