#include <bits/stdc++.h>
using namespace std;
const double eps = 1e-8;
int dcmp(double x) {
  if (fabs(x) <= eps) return 0;
  return (x > 0) ? 1 : -1;
};
namespace solver {
int n, k, m;
int v[330000];
int c[330000];
int lowbit(int x) { return x & -x; }
void add(int x) {
  for (int i = x; i < 330000; i += lowbit(i)) c[i]++;
}
int ans[330000];
int ask(int x) {
  int res = 0;
  for (int i = x; i; i -= lowbit(i)) res += c[i];
  return res;
}
int t[330000];
void solve() {
  scanf("%d", &n);
  ans[0] = 1;
  for (int i = 1; i <= n; i++) scanf("%d", &v[i]), ans[i] = 1;
  int ed = n;
  for (int i = 1; i <= n; i++) {
    t[v[i]] = 1;
    while (t[ed]) ed--;
    add(v[i]);
    ans[i] += ask(ed);
  }
  for (int i = 0; i <= n; i++) printf("%d ", ans[i]);
}
}  // namespace solver
int main() {
  solver::solve();
  return 0;
}
