0
1
mirror of https://git.sb/baoshuo/OI-codes.git synced 2025-01-23 07:11:58 +00:00

B - Climbing Takahashi

https://atcoder.jp/contests/abc235/submissions/28536973
This commit is contained in:
Baoshuo Ren 2022-01-15 20:09:23 +08:00
parent 688f92f284
commit 20c8c20afb
Signed by: baoshuo
GPG Key ID: 70F90A673FB1AB68

21
AtCoder/ABC235/B/B.cpp Normal file
View File

@ -0,0 +1,21 @@
#include <iostream>
using std::cin;
using std::cout;
using std::endl;
int n, h, ans;
int main() {
cin >> n;
for (int i = 1; i <= n; i++) {
cin >> h;
if (h <= ans) {
break;
} else {
ans = h;
}
}
cout << ans << endl;
return 0;
}