結果

問題 No.24 数当てゲーム
ユーザー turner18_jpturner18_jp
提出日時 2017-09-26 10:34:27
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
AC  
実行時間 34 ms / 5,000 ms
コード長 370 bytes
コンパイル時間 96 ms
コンパイル使用メモリ 12,416 KB
実行使用メモリ 10,752 KB
最終ジャッジ日時 2024-11-15 16:49:45
合計ジャッジ時間 922 ms
ジャッジサーバーID
(参考情報)
judge2 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 10
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
nums = ["0","1","2","3","4","5","6","7","8","9"]

for i in range(N):
    l = list(input().split())
    if l[-1] == "YES":
        temp = []
        for item in l:
            if item in nums:
                temp.append(item)
        nums = temp
    else:
        for j in l:
            if j in nums:
                nums.remove(j)

print(int(nums[0]))
0