結果

問題 No.24 数当てゲーム
ユーザー concon
提出日時 2019-06-13 21:03:54
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
実行時間 -
コード長 467 bytes
コンパイル時間 160 ms
コンパイル使用メモリ 12,800 KB
実行使用メモリ 10,880 KB
最終ジャッジ日時 2024-04-23 14:51:20
合計ジャッジ時間 1,024 ms
ジャッジサーバーID
(参考情報)
judge1 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

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

ソースコード

diff #

N=int(input())
string_list=[input() for i in range(N)]
B=[]
C=[]
D=[i for i in range(10)]
for i in range(N):
    A=string_list[i].split()
    if A[4]=="YES":
        B.append(A[:-1])
    else:
        C.append(A[:-1])

if len(B)==0:
    E=[int(x) for y in C for x in y]
    E=set(E)
    F=list(set(D) ^ E)
    print(F[0])

else:
    E=[int(x) for y in C for x in y]
    E=set(E)
    F=[int(x) for y in B for x in y]
    F=set(F)
    G=list((F & E)^ F)
    print(G[0])
0