#include <bits/stdc++.h>
using namespace std;
int n;
vector<int> v, ans, col;
int f(int k) {
  int cntcol = 0, b = 0;
  ans[k] = 0;
  for (int i = 0; i < n; ++i) {
    if (!col[v[i]]) {
      if (cntcol == k) {
        for (int j = b; j < i; ++j) --col[v[j]];
        ++ans[k];
        cntcol = 0;
        b = i;
      }
      ++cntcol;
    }
    ++col[v[i]];
  }
  ++ans[k];
  do --col[v[b]];
  while (++b < n);
  return ans[k];
}
void solve(int l, int r) {
  if (l + 1 < r) {
    int m = (l + r) >> 1, v = f(m);
    if (v == ans[l])
      for (int i = l; i <= m; ++i) ans[i] = v;
    else
      solve(l, m);
    if (v == ans[r])
      for (int i = m; i <= r; ++i) ans[i] = v;
    else
      solve(m, r);
  }
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cin >> n;
  v = vector<int>(n);
  ans = vector<int>(n + 1);
  col = vector<int>(n + 1);
  for (auto &el : v) cin >> el;
  f(1), f(n);
  if (n <= 10)
    for (int i = 2; i < n; ++i) f(i);
  else
    solve(1, n);
  for (int i = 1; i <= n; ++i) cout << ans[i] << " \n"[i == n];
  return 0;
}
