結果
| 問題 |
No.365 ジェンガソート
|
| コンテスト | |
| ユーザー |
SutoraRen
|
| 提出日時 | 2016-06-30 17:05:19 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 341 bytes |
| コンパイル時間 | 1,944 ms |
| コンパイル使用メモリ | 156,748 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-10-11 23:14:00 |
| 合計ジャッジ時間 | 3,130 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 9 WA * 32 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
#define FOR(i,a,b) for(int i=(a);i<(b);i++)
#define REP(i,a) FOR(i,0,a)
const int MAX_N=1e5;
int N;
int a[MAX_N];
int main(){
cin.tie(0);
ios::sync_with_stdio(false);
cin>>N;
REP(i,N){
cin>>a[i];
}
int ans=0;
FOR(i,1,N){
if (a[i-1]>a[i]) ans++;
}
cout<<ans<<"\n";
return 0;
}
SutoraRen