0
1
mirror of https://git.sb/baoshuo/OI-codes.git synced 2024-09-19 22:25:27 +00:00
Baoshuo Ren 2022-03-26 20:08:54 +08:00
parent 0bc6eec9da
commit 970efada90
Signed by: baoshuo
GPG Key ID: 70F90A673FB1AB68

27
AtCoder/ABC245/B/B.cpp Normal file
View File

@ -0,0 +1,27 @@
#include <algorithm>
#include <iostream>
using std::cin;
using std::cout;
const char endl = '\n';
const int N = 2005;
int n;
bool vis[N];
int main() {
std::ios::sync_with_stdio(false);
cin >> n;
for (int i = 1, x; i <= n; i++) {
cin >> x;
vis[x] = true;
}
for (int i = 0; i <= 2000; i++) {
if (!vis[i]) {
cout << i << endl;
exit(0);
}
}
return 0;
}