結果

問題 No.2442 線形写像
ユーザー t98slidert98slider
提出日時 2023-06-10 10:52:24
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 227 ms / 2,000 ms
コード長 279 bytes
コンパイル時間 298 ms
コンパイル使用メモリ 87,048 KB
実行使用メモリ 84,556 KB
最終ジャッジ日時 2023-08-26 12:16:30
合計ジャッジ時間 4,271 ms
ジャッジサーバーID
(参考情報)
judge13 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 68 ms
71,156 KB
testcase_01 AC 67 ms
71,156 KB
testcase_02 AC 71 ms
71,380 KB
testcase_03 AC 69 ms
71,632 KB
testcase_04 AC 72 ms
71,436 KB
testcase_05 AC 68 ms
71,196 KB
testcase_06 AC 68 ms
71,540 KB
testcase_07 AC 69 ms
71,408 KB
testcase_08 AC 70 ms
71,440 KB
testcase_09 AC 71 ms
71,632 KB
testcase_10 AC 79 ms
77,076 KB
testcase_11 AC 82 ms
76,932 KB
testcase_12 AC 90 ms
77,072 KB
testcase_13 AC 81 ms
76,860 KB
testcase_14 AC 83 ms
76,920 KB
testcase_15 AC 129 ms
77,828 KB
testcase_16 AC 122 ms
77,932 KB
testcase_17 AC 227 ms
84,556 KB
testcase_18 AC 168 ms
78,508 KB
testcase_19 AC 167 ms
78,468 KB
testcase_20 AC 167 ms
78,304 KB
testcase_21 AC 227 ms
84,412 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
A = [0] * (1 << N)
A[0] = int(input())

if A[0]:
    print('No')
    exit()

for S in range(1, 1 << N):
    A[S] = int(input())
    T = A[S]
    for j in range(N):
    	if S >> j & 1:
    		T ^= A[1 << j]
    
    if T:
    	print('No')
    	exit()

print('Yes')
0