#include <bits/stdc++.h>
using namespace std;
const int INF = INT_MAX;
const long long INFL = LLONG_MAX;
const long double pi = acos(-1);
int N;
int A[200100];
int ans[200100];
inline int get_parent(int n, int k) { return (n - 2) / k + 1; }
inline int add(int l, int r) {
  ans[l]++;
  ans[r + 1]--;
  return 0;
}
int main() {
  ios_base::sync_with_stdio(0);
  cout.precision(15);
  cout << fixed;
  cout.tie(0);
  cin.tie(0);
  cin >> N;
  for (int(i) = 1, j123 = N; (i) <= j123; (i)++) cin >> A[i];
  int helloworld = 2500;
  for (int n = 2; n <= N; n++) {
    int last = min(helloworld, N - 1);
    for (int k = 1; k <= last; k++) {
      int p = get_parent(n, k);
      if (A[p] > A[n]) add(k, k);
    }
    for (int k = helloworld + 1; k <= N - 1;) {
      int current_parent = get_parent(n, k);
      if (current_parent == get_parent(n, N - 1)) {
        if (A[current_parent] > A[n]) add(k, N - 1);
        break;
      } else {
        int good = k;
        int bad = n - 1;
        while (good + 1 < bad) {
          int m = (good + bad) / 2;
          if (get_parent(n, m) == current_parent)
            good = m;
          else
            bad = m;
        }
        if (A[current_parent] > A[n]) add(k, good);
        k = good + 1;
      }
    }
  }
  for (int(i) = 1, j123 = N; (i) <= j123; (i)++) ans[i] += ans[i - 1];
  for (int(i) = 1, j123 = N - 1; (i) <= j123; (i)++)
    cout << ans[i] << (i + 1 <= N - 1 ? ' ' : '\n');
}
