#include <bits/stdc++.h>
using namespace std;
const long long mod = 1000000007, ar = 200005;
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int x;
  cin >> x;
  string s;
  for (int w = 0; w < x; w++) s.push_back('o');
  vector<int> vec, res;
  for (int w = 0; w < x; w++) {
    int a;
    cin >> a;
    vec.push_back(a);
  }
  int last = s.size() - 1;
  int cur = 1;
  res.push_back(1);
  int num = 0;
  for (int w = 0; w < vec.size(); w++) {
    s[vec[w] - 1] = 'x';
    if (s[last] == 'o')
      res.push_back(++cur - num);
    else {
      for (int i = last; i >= 0; i--) {
        if (s[i] == 'o') {
          last = i;
          break;
        } else
          num++;
      }
      res.push_back(++cur - num);
    }
  }
  for (int x : res) cout << x << " ";
  return 0;
}
