#include <bits/stdc++.h>
using namespace std;
const int mod = 1000000007;
int n, p, a[300005], sum[300005], zero;
int result = 1;
int getSum(int r);
void update(int index, int delta);
int main() {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  cin >> n;
  cout << result << "\n";
  zero = n;
  for (int i = 0; i < n; i++) {
    cin >> p;
    a[p] = 1;
    update(p, 1);
    while ((zero > 0) && (a[zero] == 1)) zero--;
    if (zero == 0)
      result = 1;
    else
      result = getSum(zero) + 1;
    cout << result << "\n";
  }
  cout << "\n"
       << "\n";
  return 0;
}
int getSum(int r) {
  int res = 0;
  for (; r > -1; r = (r & (r + 1)) - 1) res += sum[r];
  return res;
}
void update(int index, int delta) {
  for (; index <= n; index |= (index + 1)) sum[index] += delta;
}
