結果

問題 No.742 にゃんにゃんにゃん 猫の挨拶
コンテスト
ユーザー x87asdf
提出日時 2018-11-04 18:31:24
言語 Java
(openjdk 25.0.2)
コンパイル:
javac -encoding UTF8 _filename_
実行:
java -ea -Xmx700m -Xss256M -DONLINE_JUDGE=true _class_
結果
RE  
実行時間 -
コード長 588 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 1,920 ms
コンパイル使用メモリ 81,556 KB
実行使用メモリ 51,992 KB
最終ジャッジ日時 2026-05-14 23:40:52
合計ジャッジ時間 4,178 ms
ジャッジサーバーID
(参考情報)
judge3_0 / judge1_1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other RE * 16
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        
        int[] destination = new int[sc.nextInt()];
        for(int i1=0;i1<destination.length;) {
            destination[i1] = sc.nextInt();
        }
        
        int count = 0;
        for(int i1=0;i1<destination.length;) {
            for(int i2=1;i2<=i1;) {
                if(destination[i1] < destination[i1-i2]) {
                    count++;
                }
            }
        }
        
        System.out.println(count);
    }
}
0