#include <bits/stdc++.h>
using namespace std;
long long power(long long a, long long b) {
  long long ans = 1;
  while (b > 0) {
    if (b & 1) {
      ans = (ans * a) % 1000000007;
    }
    a = (a * a) % 1000000007;
    b >>= 1;
  }
  return ans;
}
bool prime(long long n) {
  for (long long i = 2; i * i <= n; i++) {
    if (n % i == 0) return false;
  }
  return true;
}
int32_t main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  long long n;
  cin >> n;
  long long a[n];
  for (long long i = 0; i < n; i++) {
    cin >> a[i];
  }
  long long i = 0;
  long long x = 1;
  bool b = true;
  vector<long long> v;
  while (i < n) {
    if (a[i] == x) {
      v.push_back(2001 + i);
      b = false;
      x++;
      i++;
    } else
      i++;
  }
  cout << v.size() << endl;
  for (long long i = 0; i < v.size(); i++) cout << v[i] << " ";
  return 0;
}
