結果

問題 No.24 数当てゲーム
ユーザー shrimp334shrimp334
提出日時 2019-08-10 10:30:07
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 17 ms / 5,000 ms
コード長 625 bytes
コンパイル時間 102 ms
コンパイル使用メモリ 10,764 KB
実行使用メモリ 7,864 KB
最終ジャッジ日時 2023-09-26 23:14:29
合計ジャッジ時間 1,118 ms
ジャッジサーバーID
(参考情報)
judge11 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 17 ms
7,788 KB
testcase_01 AC 16 ms
7,792 KB
testcase_02 AC 16 ms
7,852 KB
testcase_03 AC 17 ms
7,840 KB
testcase_04 AC 16 ms
7,840 KB
testcase_05 AC 16 ms
7,780 KB
testcase_06 AC 17 ms
7,776 KB
testcase_07 AC 16 ms
7,796 KB
testcase_08 AC 17 ms
7,864 KB
testcase_09 AC 16 ms
7,788 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

def test():
    N = int(input())
    list1 = [0,1,2,3,4,5,6,7,8,9]
    list2 = []

    for i in range(N):
        list2 = (input().split())
        if "NO" in list2:
            for j in range(4):
                if int(list2[j]) in list1:
                    list1.remove(int(list2[j]))
                else:
                    pass
        if "YES" in list2:
            for k in range(10):
                if str(k) not in list2:
                    if k in list1:
                        list1.remove(k)
                    else:
                        pass

    print(list1[0])


if __name__ == "__main__":
    test() 
0