#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int n;
  cin >> n;
  int c = 0, p;
  int a[n + 1];
  for (int i = 1; i <= n; i++) cin >> a[i];
  sort(a + 1, a + n + 1);
  if (a[1] != 1)
    cout << 1 << "\n";
  else {
    for (int i = 2; i <= n; i++) {
      if (a[i] - a[i - 1] != 1) {
        c = 1;
        p = a[i - 1] + 1;
        break;
      }
    }
    if (c)
      cout << p << "\n";
    else
      cout << n + 1 << "\n";
  }
}
