結果
| 問題 | No.365 ジェンガソート | 
| コンテスト | |
| ユーザー |  Akidai | 
| 提出日時 | 2020-03-29 11:32:39 | 
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) | 
| 結果 | 
                                WA
                                 
                             | 
| 実行時間 | - | 
| コード長 | 355 bytes | 
| コンパイル時間 | 1,743 ms | 
| コンパイル使用メモリ | 160,924 KB | 
| 実行使用メモリ | 6,824 KB | 
| 最終ジャッジ日時 | 2025-01-02 13:15:16 | 
| 合計ジャッジ時間 | 4,546 ms | 
| ジャッジサーバーID (参考情報) | judge1 / judge2 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | AC * 16 WA * 25 | 
ソースコード
#include <bits/stdc++.h>
using namespace std;
#define REP(i, init, n) for(int i = (int)(init); i < (int)(n); i++)
int main() {
    int N;
    cin>>N;
    vector<int> A(N, 0);
    REP(i, 0, N) cin>>A[i];
    int Amax = 0; int count = 0;
    REP(i, 0, N){
        if(Amax > A[i]) count++;
        Amax = max(Amax, A[i]);
    }
    cout << count << endl;
}
            
            
            
        