結果

問題 No.24 数当てゲーム
ユーザー coder_So_heycoder_So_hey
提出日時 2023-01-13 23:03:57
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 75 ms / 5,000 ms
コード長 480 bytes
コンパイル時間 333 ms
コンパイル使用メモリ 87,056 KB
実行使用メモリ 71,536 KB
最終ジャッジ日時 2023-08-26 04:48:02
合計ジャッジ時間 1,889 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 73 ms
71,124 KB
testcase_01 AC 73 ms
71,296 KB
testcase_02 AC 73 ms
71,536 KB
testcase_03 AC 75 ms
71,496 KB
testcase_04 AC 74 ms
71,420 KB
testcase_05 AC 73 ms
71,352 KB
testcase_06 AC 74 ms
71,388 KB
testcase_07 AC 75 ms
71,292 KB
testcase_08 AC 73 ms
71,420 KB
testcase_09 AC 75 ms
71,044 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
num = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
cand = []
answer = []
bool = False

for i in range(N):
    A, B, C, D, R = map(str, input().split())
    A, B, C, D = int(A), int(B), int(C), int(D)
    if R == "NO":
        num[int(A)] = -1
        num[int(B)] = -1
        num[int(C)] = -1
        num[int(D)] = -1
    else:
        for i in range(10):
            if num[i] != A and num[i] != B and num[i] != C and num[i] != D:
                num[i] = -1

print(max(num))
0