#include <bits/stdc++.h>
using namespace std;
int mult(int x, int y) {
  long long int ans, x1 = (long long int)x, y1 = (long long int)y;
  ans = (x1 * y1) % 1000000007;
  return (int)ans;
}
int gcd(int a, int b) { return b == 0 ? a : gcd(b, a % b); }
int lcm(int a, int b) { return a * (b / gcd(a, b)); }
long long int pow1(long long int a, long long int b) {
  long long int ans = 1;
  while (b > 0) {
    if (b & 1) ans = (ans * a) % 1000000007;
    a = (a * a) % 1000000007;
    b >>= 1;
  }
  return ans;
}
int n;
struct node {
  int value, priority, sz, reverse;
  node *left, *right;
};
typedef node *pnode;
int getsize(pnode node) {
  if (!node) return 0;
  return node->sz;
}
void refresh(pnode node) {
  if (!node) return;
  node->sz = getsize(node->left) + getsize(node->right) + 1;
}
void merge(pnode &result, pnode l, pnode r) {
  if (!l || !r) {
    result = (l ? l : r);
    return;
  }
  if (l->priority > r->priority) {
    merge(l->right, l->right, r);
    result = l;
  } else {
    merge(r->left, l, r->left);
    result = r;
  }
  refresh(result);
}
void split(pnode node, pnode &l, pnode &r, int pos) {
  if (!node) {
    l = r = node;
    return;
  }
  if (node->value <= pos) {
    split(node->right, node->right, r, pos);
    l = node;
  } else {
    split(node->left, l, node->left, pos);
    r = node;
  }
  refresh(node);
}
pnode create(int val) {
  pnode temp = new node();
  temp->priority = rand();
  temp->sz = 1;
  temp->left = temp->right = NULL;
  temp->value = val;
  temp->reverse = 0;
  return temp;
}
void insert(pnode &node, int val) {
  pnode l, r;
  split(node, l, r, val - 1);
  merge(l, l, create(val));
  merge(node, l, r);
}
void remove(pnode &node, int val) {
  pnode l, r, tmp;
  split(node, l, r, val - 1);
  split(r, tmp, r, val);
  merge(node, l, r);
}
int kth(pnode &node, int k) {
  int tmpsz = getsize(node->left);
  if (k <= tmpsz) return kth(node->left, k);
  if (k > tmpsz + 1) return kth(node->right, k - tmpsz - 1);
  return node->value;
}
int getpos(pnode &node, int k) {
  if (getsize(node) < k) return n + 1;
  return kth(node, k);
}
void print(pnode &node) {
  if (!node) return;
  print(node->left);
  printf("%d ", node->value);
  print(node->right);
}
pnode tree = NULL;
int a[100005], ans[100005];
vector<vector<int> > v, g;
int main() {
  int i, j;
  scanf("%d", &n);
  v.resize(n + 2);
  g.resize(n + 2);
  for (i = 1; i < n + 1; i++) {
    scanf("%d", &a[i]);
    g[a[i]].push_back(i);
  }
  for (i = 1; i < n + 1; i++) v[1].push_back(i);
  for (i = 1; i < n + 1; i++) {
    reverse(g[i].begin(), g[i].end());
    if (!g[i].size()) continue;
    insert(tree, g[i].back());
  }
  for (i = 1; i < n + 1; i++) {
    for (j = 0; j < v[i].size(); j++) {
      int nxt = getpos(tree, v[i][j] + 1);
      ++ans[v[i][j]];
      if (nxt < n + 1) v[nxt].push_back(v[i][j]);
    }
    remove(tree, g[a[i]].back());
    g[a[i]].pop_back();
    if (!g[a[i]].empty()) insert(tree, g[a[i]].back());
  }
  for (i = 1; i < n + 1; i++) printf("%d ", ans[i]);
  printf("\n");
  return 0;
}
