#include <bits/stdc++.h>
using namespace std;
int n, a[100010], ans[100010], c[100010];
int get(int k) {
  if (ans[k] > 0) {
    return ans[k];
  }
  int res = 1, cnt = 0;
  memset(c, 0, sizeof(c));
  for (int i = 1; i <= n; i++) {
    if (c[a[i]] == res) {
      continue;
    }
    c[a[i]] = res;
    cnt++;
    if (cnt > k) {
      res++;
      cnt = 1;
      c[a[i]] = res;
    }
  }
  return res;
}
void solve(int l, int r) {
  if (l > r) {
    return;
  }
  int resl = get(l);
  int resr = get(r);
  if (resl == resr) {
    for (int i = l; i <= r; i++) {
      ans[i] = resl;
    }
    return;
  }
  ans[l] = resl;
  ans[r] = resr;
  int mid = (l + r) >> 1;
  solve(l + 1, mid);
  solve(mid + 1, r - 1);
}
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) {
    scanf("%d", &a[i]);
  }
  solve(1, n);
  for (int i = 1; i <= n; i++) {
    printf("%d ", ans[i]);
  }
  return 0;
}
