#include <bits/stdc++.h>
using namespace std;
int n, a[1000000], bo[1000000];
int check(int i) {
  int l = 1, r = 1, ans = 0;
  do {
    int cnt = 0;
    for (; r <= n + 1; r++) {
      if (bo[a[r]] == 0 && r <= n) {
        bo[a[r]] = 1;
        ++cnt;
        if (cnt > i) break;
      }
    }
    for (int j = l; j <= r; j++) bo[a[j]] = 0;
    l = r;
    ++ans;
  } while (l <= n);
  return ans;
}
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
  int m = sqrt(n);
  for (int i = 1; i <= m; i++) printf("%d ", check(i));
  int l = m, pre = m;
  for (int i = check(m); i; i--) {
    if (check(l) != i) continue;
    int r = n + 1, mid = (l + r) >> 1;
    do {
      if (check(mid) == i)
        l = mid;
      else
        r = mid;
      mid = (l + r) >> 1;
    } while (l + 1 < r);
    for (int j = pre + 1; j <= l; j++) printf("%d ", i);
    pre = l;
    ++l;
  }
}
