結果

問題 No.504 ゲーム大会(ランキング)
ユーザー _KingdomOfMoray_KingdomOfMoray
提出日時 2019-11-27 15:58:57
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
TLE  
実行時間 -
コード長 367 bytes
コンパイル時間 135 ms
コンパイル使用メモリ 12,672 KB
実行使用メモリ 35,356 KB
最終ジャッジ日時 2024-04-25 22:45:46
合計ジャッジ時間 4,875 ms
ジャッジサーバーID
(参考情報)
judge2 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 25 ms
17,820 KB
testcase_01 AC 27 ms
10,752 KB
testcase_02 AC 27 ms
10,752 KB
testcase_03 AC 25 ms
10,880 KB
testcase_04 AC 24 ms
10,752 KB
testcase_05 AC 26 ms
10,752 KB
testcase_06 AC 26 ms
10,752 KB
testcase_07 TLE -
testcase_08 -- -
testcase_09 -- -
testcase_10 -- -
testcase_11 -- -
testcase_12 -- -
testcase_13 -- -
testcase_14 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())
a = [int(input()) for i in range(n)]

b = []
for i in range(n):
    cur = []
    cur.append(i)
    cur.append(a[i])
    b.append(cur)

for i in range(n):
    cur = b[:i+1]
    sorted_cur = sorted(cur, reverse=True, key=lambda x:x[1])
    
    for j in range(len(sorted_cur)):
        if sorted_cur[j][0] == 0:
            print(j+1)
            break
0