#include <bits/stdc++.h>
using namespace std;
int main() {
  long long i, j, k, l, n, q, p, coun = 1, m = 0;
  cin >> n;
  vector<long long> arr(n);
  vector<long long> crr(n, 0);
  for (int i = 0; i < n; i++) {
    cin >> arr[i];
  }
  cout << "1 ";
  k = n - 1;
  for (int i = 0; i < n; i++) {
    crr[arr[i] - 1] = 1;
    if (arr[i] - 1 == k) {
      if (crr[k - 1] == 1) {
        while (crr[k] == 1) {
          k--;
          coun--;
        }
        coun++;
      } else {
        k--;
      }
    } else {
      coun++;
    }
    cout << coun << " ";
  }
  cout << endl;
  return 0;
}
