#include <bits/stdc++.h>
const int maxn = 3e5 + 20;
int n;
int end;
int p[maxn];
int a[maxn];
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d", &p[i]);
  end = n;
  printf("1 ");
  for (int i = 1; i <= n; i++) {
    a[p[i]] = 1;
    while (end >= 1 && a[end] == 1) end--;
    printf("%d ", i - (n - end) + 1);
  }
  return 0;
}
