#include <bits/stdc++.h>
using namespace std;
int n, a[300020], f[300020];
int main() {
  ios_base::sync_with_stdio(false);
  cout << 1 << endl;
  cin >> n;
  int k = n;
  for (int i = 1; i <= n; ++i) {
    cin >> a[i];
    f[a[i]] = 1;
    while (f[k]) k--;
    cout << " " << i + 2 - (n - k + 1);
  }
  cout << endl;
  return 0;
}
