#include <bits/stdc++.h>
int main() {
  std::ifstream fin("input.txt");
  std::ofstream fout("output.txt");
  int elementsNumber;
  std::cin >> elementsNumber;
  std::vector<int> inputArray(elementsNumber + 5);
  std::vector<int> delta(elementsNumber + 5);
  for (int index = 0; index < elementsNumber; ++index) {
    std::cin >> inputArray[index];
  }
  for (int elementIndex = 1; elementIndex < elementsNumber; ++elementIndex) {
    for (int parent = 0, bord = (int)std::sqrt(elementIndex); parent < bord;
         ++parent) {
      if (inputArray[elementIndex] < inputArray[parent]) {
        int leftConnect = (elementIndex - 1) / (parent + 1) + 1;
        int rightConnect = elementsNumber;
        if (parent != 0) {
          rightConnect = (elementIndex - 1) / parent + 1;
        }
        ++delta[leftConnect];
        --delta[rightConnect];
      }
    }
    for (int connect = (elementIndex - 1) / (int)std::sqrt(elementIndex);
         connect >= 1; --connect) {
      if (inputArray[elementIndex] < inputArray[(elementIndex - 1) / connect]) {
        ++delta[connect];
        --delta[connect + 1];
      }
    }
  }
  int sum = 0;
  for (int connect = 1; connect < elementsNumber; ++connect) {
    sum += delta[connect];
    std::cout << sum << " ";
  }
  return 0;
}
