結果

問題 No.504 ゲーム大会(ランキング)
ユーザー n120aosssssssssn120aosssssssss
提出日時 2017-05-14 16:51:56
言語 PHP
(8.3.4)
結果
WA  
実行時間 -
コード長 353 bytes
コンパイル時間 48 ms
コンパイル使用メモリ 12,176 KB
実行使用メモリ 16,668 KB
最終ジャッジ日時 2023-10-14 10:57:36
合計ジャッジ時間 3,975 ms
ジャッジサーバーID
(参考情報)
judge15 / judge14
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 TLE -
testcase_08 -- -
testcase_09 -- -
testcase_10 -- -
testcase_11 -- -
testcase_12 -- -
testcase_13 -- -
testcase_14 -- -
権限があれば一括ダウンロードができます
コンパイルメッセージ
No syntax errors detected in Main.php

ソースコード

diff #

<?php
    $N = trim(fgets(STDIN));
    $scores = array();
    for($i = 1; $i <= $N; $i++) {
    	$scores[] = trim(fgets(STDIN));
    	if($i == 1) {
    		$kScore = $scores[0];
    	}
    	rsort($scores);
    	for($j = 0; $j < count($scores); $j++) {
    		if($kScore == $scores[$j]) {
    			 printf("($j+1)\n");
    			 break;
    		}
    	}
    }
    
0