結果
問題 | No.365 ジェンガソート |
ユーザー |
|
提出日時 | 2019-08-15 02:08:49 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 35 ms / 2,000 ms |
コード長 | 255 bytes |
コンパイル時間 | 2,259 ms |
コンパイル使用メモリ | 192,312 KB |
最終ジャッジ日時 | 2025-01-07 11:51:55 |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 41 |
ソースコード
#include <bits/stdc++.h> using namespace std; typedef long long ll; int main() { int n; cin>>n; int a[n]; for(int i=0;i<n;i++)cin>>a[i]; for (int i=n-1;i>=0;i--) if (a[i]==n) n--; cout<<n<<endl; return 0; }