#include <bits/stdc++.h>
using namespace std;
const int MAXN = 200005;
int a[MAXN], n;
vector<int> q[MAXN];
int hehe(int x) { return (-x) & x; }
void add(int p, int x) {
  while (p <= n) {
    q[p].push_back(x);
    p += hehe(p);
  }
}
int query(int p, int val) {
  int res = 0;
  while (p >= 1) {
    res += lower_bound(q[p].begin(), q[p].end(), val) - q[p].begin();
    p -= hehe(p);
  }
  return res;
}
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) {
    scanf("%d", &a[i]);
    add(i, a[i]);
  }
  for (int i = 1; i <= n; i++) {
    sort(q[i].begin(), q[i].end());
  }
  for (int k = 1; k < n; k++) {
    int pos = 1;
    int ans = 0;
    for (int j = 1; j <= n; j += k) {
      if (pos > n - 1) break;
      int val = a[pos];
      int l = j + 1;
      int r = min(j + k, n);
      if (l > r) break;
      int vall = query(l - 1, val);
      int valr = query(r, val);
      ans += valr - vall;
      pos++;
    }
    printf("%d ", ans);
  }
  puts("");
  return 0;
}
