結果

問題 No.24 数当てゲーム
ユーザー osrgy01osrgy01
提出日時 2020-12-25 10:21:38
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
実行時間 -
コード長 380 bytes
コンパイル時間 274 ms
コンパイル使用メモリ 11,776 KB
実行使用メモリ 10,068 KB
最終ジャッジ日時 2023-10-22 02:02:00
合計ジャッジ時間 1,070 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

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

ソースコード

diff #

y1,y2,n=set(),set(),set()
ans=set(*['0123456789'])
for _ in range(int(input())):
    a,b,c,d,e=input().split()
    if e=='YES':
        if y1:
            for i in [a,b,c,d]:
                y2.add(i)
            y1&=y2
        else:
            for i in [a,b,c,d]:
                y1.add(i)
    else:
        for i in [a,b,c,d]:
            n.add(i)
print(*y1-n if y1 else ans^n)
0