結果

問題 No.24 数当てゲーム
ユーザー HIROPON87069639HIROPON87069639
提出日時 2016-02-27 19:18:45
言語 Python2
(2.7.18)
結果
AC  
実行時間 12 ms / 5,000 ms
コード長 316 bytes
コンパイル時間 116 ms
コンパイル使用メモリ 7,088 KB
実行使用メモリ 6,476 KB
最終ジャッジ日時 2023-10-24 18:37:24
合計ジャッジ時間 758 ms
ジャッジサーバーID
(参考情報)
judge14 / judge12
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 12 ms
6,476 KB
testcase_01 AC 12 ms
6,476 KB
testcase_02 AC 11 ms
6,476 KB
testcase_03 AC 11 ms
6,476 KB
testcase_04 AC 11 ms
6,476 KB
testcase_05 AC 11 ms
6,476 KB
testcase_06 AC 12 ms
6,476 KB
testcase_07 AC 12 ms
6,476 KB
testcase_08 AC 11 ms
6,476 KB
testcase_09 AC 11 ms
6,476 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

# -*- coding: utf-8 -*-
N = input()
ref = [0] * 10
A = [0] * 4
for i in range(N):
    tmp = raw_input().split()
    A[0:4] = map(int, tmp[0:4])
    R = tmp[4]
    if R == "NO":
        cnt = -1
    elif R == "YES":
        cnt = 1
    for j in range(4):
        ref[A[j]] += cnt
rmax = max(ref)
print ref.index(rmax)
0