結果

問題 No.1795 AtCoder Heuristic Rating coloring
ユーザー harurunharurun
提出日時 2021-11-14 21:48:08
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 507 ms / 2,000 ms
コード長 322 bytes
コンパイル時間 100 ms
コンパイル使用メモリ 11,840 KB
実行使用メモリ 33,944 KB
最終ジャッジ日時 2023-10-20 07:23:14
合計ジャッジ時間 12,722 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 29 ms
10,044 KB
testcase_01 AC 29 ms
10,044 KB
testcase_02 AC 28 ms
10,044 KB
testcase_03 AC 29 ms
10,048 KB
testcase_04 AC 37 ms
10,484 KB
testcase_05 AC 41 ms
10,484 KB
testcase_06 AC 39 ms
10,504 KB
testcase_07 AC 39 ms
10,528 KB
testcase_08 AC 40 ms
10,540 KB
testcase_09 AC 41 ms
10,620 KB
testcase_10 AC 40 ms
10,592 KB
testcase_11 AC 38 ms
10,544 KB
testcase_12 AC 29 ms
10,048 KB
testcase_13 AC 29 ms
10,056 KB
testcase_14 AC 29 ms
10,052 KB
testcase_15 AC 29 ms
10,048 KB
testcase_16 AC 29 ms
10,056 KB
testcase_17 AC 29 ms
10,052 KB
testcase_18 AC 29 ms
10,052 KB
testcase_19 AC 29 ms
10,048 KB
testcase_20 AC 29 ms
10,060 KB
testcase_21 AC 28 ms
10,052 KB
testcase_22 AC 29 ms
10,052 KB
testcase_23 AC 28 ms
10,052 KB
testcase_24 AC 29 ms
10,056 KB
testcase_25 AC 28 ms
10,052 KB
testcase_26 AC 29 ms
10,052 KB
testcase_27 AC 29 ms
10,056 KB
testcase_28 AC 31 ms
10,048 KB
testcase_29 AC 28 ms
10,056 KB
testcase_30 AC 31 ms
10,052 KB
testcase_31 AC 30 ms
10,048 KB
testcase_32 AC 234 ms
17,896 KB
testcase_33 AC 163 ms
16,556 KB
testcase_34 AC 338 ms
21,420 KB
testcase_35 AC 289 ms
20,116 KB
testcase_36 AC 320 ms
22,180 KB
testcase_37 AC 185 ms
16,816 KB
testcase_38 AC 184 ms
17,104 KB
testcase_39 AC 358 ms
22,200 KB
testcase_40 AC 248 ms
18,404 KB
testcase_41 AC 344 ms
21,408 KB
testcase_42 AC 214 ms
17,876 KB
testcase_43 AC 231 ms
18,932 KB
testcase_44 AC 296 ms
21,388 KB
testcase_45 AC 224 ms
17,876 KB
testcase_46 AC 377 ms
22,704 KB
testcase_47 AC 110 ms
13,684 KB
testcase_48 AC 205 ms
18,424 KB
testcase_49 AC 378 ms
22,972 KB
testcase_50 AC 210 ms
17,084 KB
testcase_51 AC 187 ms
16,556 KB
testcase_52 AC 415 ms
24,928 KB
testcase_53 AC 425 ms
24,932 KB
testcase_54 AC 494 ms
33,944 KB
testcase_55 AC 507 ms
33,940 KB
testcase_56 AC 505 ms
33,944 KB
testcase_57 AC 503 ms
33,936 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from collections import Counter
def main():
  N,M=map(int,input().split())
  d=Counter()
  for i in range(N):
    S,A=input().split()
    d[S]=int(A)
  for i in range(M):
    T,B=input().split()
    d[T]=int(B)
  ans=sorted(list(d.items()),key=lambda x:x[0])
  for user,rate in ans:
    print(user,rate)
  return

main()

0