#include <bits/stdc++.h>
using namespace std;
int static fast = []() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  return 0;
}();
int main() {
  int n, pos;
  cin >> n;
  vector<int> used(n + 1, 0);
  cout << 1 << " ";
  int cnt = 0;
  for (int i = 0; i < n; i++) {
    cin >> pos;
    cnt += 1;
    used[pos] += 1;
    while (used.back() == 1) {
      cnt -= 1;
      used.pop_back();
    }
    cout << cnt + 1 << " ";
  }
  return 0;
}
