#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  long long n, a;
  cin >> n;
  long long p = n;
  set<long long> s;
  cout << 1 << " ";
  for (long long i = 0; i < n; i++) {
    cin >> a;
    s.insert(a);
    if (a == p) {
      while (s.count(p) > 0) {
        s.erase(p);
        p--;
      }
    }
    cout << s.size() + 1 << " ";
  }
  return 0;
}
