#include <bits/stdc++.h>
#pragma GCC optimize "trapv"
using namespace std;
int main() {
  int n;
  cin >> n;
  vector<long long> arr(n);
  for (int i = 0; i < n; i++) cin >> arr[i];
  long long q[n + 1];
  for (int i = 0; i < n + 1; i++) q[i] = -1;
  long long che = 0;
  for (int i = 1; i < (int)sqrt(n); i++) {
    int count1 = 1;
    int size = 0;
    for (int j = 0; j < n; j++) {
      if (q[arr[j]] != che) {
        if (size == i) {
          size = 0;
          che++;
          count1++;
        }
        q[arr[j]] = che;
        size++;
      }
    }
    che++;
    cout << count1 << " ";
  }
  int count = 1;
  unordered_set<int> s;
  int curr = (int)sqrt(n);
  int t = 0;
  long long freq[(int)sqrt(n) + 3][n + 1];
  for (int i = 0; i < (int)sqrt(n) + 3; i++)
    for (int j = 0; j < n + 1; j++) freq[i][j] = 0;
  vector<pair<long long, long long> > ptr((int)sqrt(n) + 3);
  ptr[0].first = 0;
  for (int i = 0; i < n; i++) {
    if (s.find(arr[i]) == s.end()) {
      if (s.size() == curr) {
        s.clear();
        ptr[t].second = i - 1;
        count++;
        t++;
        ptr[t].first = i;
      }
      s.insert(arr[i]);
    }
    freq[t][arr[i]]++;
  }
  ptr[t].second = n - 1;
  cout << t + 1 << " ";
  for (int i = curr + 1; i <= n; i++) {
    for (int j = 0; j <= t; j++) {
      int r = i - 1;
      if (j != 0 && ptr[j - 1].second >= ptr[j].first) {
        for (int k = ptr[j].first; k <= ptr[j - 1].second; k++) {
          freq[j][arr[k]]--;
          if (freq[j][arr[k]] == 0) r--;
        }
        ptr[j].first = ptr[j - 1].second + 1;
      }
      if (ptr[j].second == n - 1) break;
      int k = ptr[j].second + 1;
      while (k != n) {
        if (freq[j][arr[k]] == 0 && r == i) {
          ptr[j].second = k - 1;
          break;
        }
        freq[j][arr[k]]++;
        if (freq[j][arr[k]] == 1) r++;
        if (k == n - 1) {
          ptr[j].second = n - 1;
          t = j;
          break;
        }
        k++;
      }
    }
    cout << t + 1 << " ";
  }
  cout << endl;
}
