結果

問題 No.2442 線形写像
ユーザー mattu34mattu34
提出日時 2023-09-04 23:34:15
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 361 bytes
コンパイル時間 1,179 ms
コンパイル使用メモリ 86,804 KB
実行使用メモリ 88,560 KB
最終ジャッジ日時 2023-09-04 23:34:24
合計ジャッジ時間 5,517 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 92 ms
71,456 KB
testcase_01 AC 93 ms
71,168 KB
testcase_02 AC 98 ms
71,168 KB
testcase_03 AC 92 ms
71,452 KB
testcase_04 AC 91 ms
71,624 KB
testcase_05 AC 92 ms
71,396 KB
testcase_06 AC 95 ms
71,604 KB
testcase_07 AC 92 ms
71,404 KB
testcase_08 WA -
testcase_09 WA -
testcase_10 AC 101 ms
76,568 KB
testcase_11 WA -
testcase_12 AC 112 ms
77,360 KB
testcase_13 AC 113 ms
77,268 KB
testcase_14 WA -
testcase_15 AC 149 ms
78,216 KB
testcase_16 AC 151 ms
78,144 KB
testcase_17 AC 242 ms
88,560 KB
testcase_18 WA -
testcase_19 AC 192 ms
78,908 KB
testcase_20 AC 194 ms
78,904 KB
testcase_21 AC 266 ms
88,488 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from collections import *
import heapq

N = int(input())
A = [int(input()) for _ in range(2**N)]
if A[0] != 0:
    print("No")
    exit()
for i in range(1 << N):
    if i % 2 == 0:
        continue
    now = 0
    for j in range(17):
        if (i >> j) & 1 == 1:
            now ^= A[1 << j]
    if now != A[i]:
        print("No")
        exit()
print("Yes")
0