#include <bits/stdc++.h>
using namespace std;
long long int stringtoLLI(string str) {
  long long int val;
  stringstream ss;
  ss << str;
  ss >> val;
  return val;
}
string LLItostring(long long int val) {
  string str;
  stringstream ss;
  ss << val;
  ss >> str;
  return str;
}
long long int n, m, k, ar[100009], fst[100009], snd[100009], table[100009];
string str;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  ;
  while (cin >> n) {
    for (int i = 0; i < n; i++) {
      cin >> ar[i];
    }
    sort(ar, ar + n);
    long long int val = ar[0];
    if (val > 1) val = 1;
    ar[0] = val;
    for (int i = 1; i < n; i++) {
      if (abs(ar[i] - val) > 1) ar[i] = val + 1;
      val = ar[i];
    }
    long long int mx = INT_MIN;
    for (int i = 0; i < n; i++) {
      if (mx < ar[i]) mx = ar[i];
    }
    cout << mx + 1 << endl;
  }
  return 0;
}
