#include <bits/stdc++.h>
using namespace std;
const int N = 100010;
const int M = 1010;
const int INF = 0x3f3f3f3f;
const int mod = 1000000007;
long long qpow(long long a, long long b) {
  long long ans = 1;
  while (b) {
    if (b & 1) ans = ans * a % mod;
    a = a * a % mod;
    b /= 2;
  }
  return ans;
}
long long qpow(long long a, long long b, long long c) {
  long long ans = 1;
  while (b) {
    if (b & 1) ans = ans * a % c;
    a = a * a % c;
    b /= 2;
  }
  return ans;
}
int n, a[N], ans[N], b[N];
int get(int x) {
  int num = 0, ans = 1;
  memset(b, 0, sizeof(b));
  for (int i = 1; i <= n; i++) {
    if (b[a[i]] == ans) continue;
    b[a[i]] = ans;
    num++;
    if (num > x) {
      num = 1;
      ans++;
      b[a[i]] = ans;
    }
  }
  return ans;
}
void solve(int l, int r) {
  if (r < l) return;
  int numl = get(l), numr = get(r);
  if (numl == numr) {
    for (int i = l; i <= r; i++) ans[i] = numl;
    return;
  }
  ans[l] = numl;
  ans[r] = numr;
  int m = l + r >> 1;
  solve(m + 1, r - 1);
  solve(l + 1, m);
}
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]);
}
