結果
問題 | No.447 ゆきこーだーの雨と雪 (2) |
ユーザー | maesora |
提出日時 | 2016-12-02 21:58:05 |
言語 | Python3 (3.12.2 + numpy 1.26.4 + scipy 1.12.0) |
結果 |
AC
|
実行時間 | 78 ms / 2,000 ms |
コード長 | 779 bytes |
コンパイル時間 | 102 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 12,416 KB |
最終ジャッジ日時 | 2024-05-05 17:56:13 |
合計ジャッジ時間 | 2,623 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 31 ms
10,752 KB |
testcase_01 | AC | 32 ms
10,752 KB |
testcase_02 | AC | 33 ms
10,752 KB |
testcase_03 | AC | 45 ms
10,880 KB |
testcase_04 | AC | 41 ms
10,880 KB |
testcase_05 | AC | 59 ms
12,032 KB |
testcase_06 | AC | 67 ms
12,288 KB |
testcase_07 | AC | 54 ms
11,264 KB |
testcase_08 | AC | 54 ms
11,648 KB |
testcase_09 | AC | 70 ms
12,288 KB |
testcase_10 | AC | 38 ms
10,880 KB |
testcase_11 | AC | 45 ms
11,136 KB |
testcase_12 | AC | 46 ms
11,392 KB |
testcase_13 | AC | 63 ms
12,160 KB |
testcase_14 | AC | 70 ms
12,416 KB |
testcase_15 | AC | 45 ms
11,136 KB |
testcase_16 | AC | 38 ms
11,136 KB |
testcase_17 | AC | 44 ms
11,008 KB |
testcase_18 | AC | 35 ms
11,008 KB |
testcase_19 | AC | 78 ms
12,416 KB |
testcase_20 | AC | 71 ms
12,416 KB |
testcase_21 | AC | 44 ms
11,264 KB |
testcase_22 | AC | 43 ms
11,136 KB |
testcase_23 | AC | 50 ms
11,136 KB |
testcase_24 | AC | 67 ms
12,032 KB |
testcase_25 | AC | 76 ms
12,416 KB |
testcase_26 | AC | 56 ms
11,264 KB |
testcase_27 | AC | 53 ms
11,264 KB |
ソースコード
# coding: utf-8 import math N = int(input()) pLevels = tuple(map(int, input().split())) T = int(input()) pAccepted = [0] * N contestants = {} for i in range(T): s = input().strip().split() name = s[0] p = ord(s[1]) - ord("A") if name not in contestants: contestants[name] = [0] * (N + 1) pl = pLevels[p] score = 50 * pl + 50 * pl / (1 + 0.2 * pAccepted[p]) contestants[name][p] = math.floor(score) pAccepted[p] += 1 contestants[name][N] = i i = 1 for name, scores in sorted(contestants.items(), key=lambda x: (-sum(x[1][:-1]), x[1][-1])): print("{} {name} {scores} {sum}".format( i, name=name, scores=" ".join([str(s) for s in scores[:-1]]), sum=sum(scores[:-1]))) i += 1