#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, x = 1;
  cin >> n;
  int a[n];
  vector<int> ans;
  for (int i = 0; i < n; i++) cin >> a[i];
  for (int i = 0; i < n; i++) {
    if (a[i] == x) {
      ans.push_back(2000 + i + 1);
      x++;
    }
  }
  cout << ans.size() << endl;
  for (auto z : ans) cout << z << ' ';
  return 0;
}
