結果

問題 No.2442 線形写像
ユーザー lloyzlloyz
提出日時 2023-08-25 21:51:00
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 377 bytes
コンパイル時間 1,089 ms
コンパイル使用メモリ 86,920 KB
実行使用メモリ 87,504 KB
最終ジャッジ日時 2023-08-25 21:51:04
合計ジャッジ時間 3,312 ms
ジャッジサーバーID
(参考情報)
judge11 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 72 ms
71,232 KB
testcase_01 AC 71 ms
71,236 KB
testcase_02 AC 72 ms
71,124 KB
testcase_03 AC 72 ms
70,940 KB
testcase_04 WA -
testcase_05 AC 72 ms
70,940 KB
testcase_06 WA -
testcase_07 AC 71 ms
71,152 KB
testcase_08 AC 77 ms
71,152 KB
testcase_09 WA -
testcase_10 AC 73 ms
71,048 KB
testcase_11 WA -
testcase_12 WA -
testcase_13 AC 71 ms
71,048 KB
testcase_14 AC 89 ms
76,696 KB
testcase_15 WA -
testcase_16 WA -
testcase_17 AC 112 ms
77,368 KB
testcase_18 WA -
testcase_19 WA -
testcase_20 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input = sys.stdin.readline

n = int(input())
A = [int(input()) for _ in range(pow(2, n))]

if A[0] != 0:
    print("No")
    exit()
if n >= 2:
    for i in range(1, n):
        temp = A[pow(2, i)]
        for j in range(pow(2, i) - 1):
            res = temp ^ A[i + j]
            if res != A[j + 1]:
                print("No")
                exit()
print("Yes")
0