| 比赛 | ICPC复现(AI数据) | 评测结果 | AAAAAAAAAA |
|---|---|---|---|
| 题目名称 | 停车难题 | 最终得分 | 100 |
| 用户昵称 | 彭欣越 | 运行时间 | 0.041 s |
| 代码语言 | C++ | 内存使用 | 3.68 MiB |
| 提交时间 | 2026-05-26 19:13:12 | ||
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int N=1010;
int n,a[N],t;
int main () {
freopen("tingche.in","r",stdin);
freopen("tingche.out","w",stdout);
ios::sync_with_stdio(0);
cin.tie(0),cout.tie(0);
cin >> n;
for (int i=1;i<=n;i++) {
cin >> a[i];
if (a[i]==t) {
t++;
}else{
break;
}
}
cout << t <<endl;
return 0;
}