#include <bits/stdc++.h>
using namespace std;
int main() {
  int p[3500];
  int n;
  cin >> n;
  bool b = 1;
  int j = 1;
  for (int i = 1; i <= n; i++) {
    cin >> p[i];
  }
  sort(p + 1, p + n + 1);
  for (int i = 1; i <= n; i++) {
    if (p[i] != j) {
      cout << j;
      return 0;
    } else {
      j++;
    }
  }
  cout << p[n] + 1;
  return 0;
}
