結果

問題 No.504 ゲーム大会(ランキング)
ユーザー YamaKasa
提出日時 2018-06-01 01:03:15
言語 Java
(openjdk 23)
結果
AC  
実行時間 1,187 ms / 2,000 ms
コード長 414 bytes
コンパイル時間 2,110 ms
コンパイル使用メモリ 74,060 KB
実行使用メモリ 69,636 KB
最終ジャッジ日時 2024-06-30 08:45:47
合計ジャッジ時間 13,681 ms
ジャッジサーバーID
(参考情報)
judge2 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 13
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();
		int a = scan.nextInt();
		int rank = 1;
		System.out.println(1);
		for(int i = 0; i < N - 1; i++) {
			int t = scan.nextInt();
			if(a >= t) {
				System.out.println(rank);
			}else {
				rank ++;
				System.out.println(rank);
			}
		}
		scan.close();
	}
}
0