結果

問題 No.1456 Range Xor
ユーザー roarisroaris
提出日時 2021-03-31 21:01:15
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 130 ms / 2,000 ms
コード長 281 bytes
コンパイル時間 797 ms
コンパイル使用メモリ 87,152 KB
実行使用メモリ 102,816 KB
最終ジャッジ日時 2023-08-21 18:40:31
合計ジャッジ時間 8,135 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 89 ms
71,636 KB
testcase_01 AC 91 ms
71,624 KB
testcase_02 AC 92 ms
71,776 KB
testcase_03 AC 116 ms
92,324 KB
testcase_04 AC 117 ms
93,844 KB
testcase_05 AC 124 ms
100,276 KB
testcase_06 AC 117 ms
92,196 KB
testcase_07 AC 127 ms
102,816 KB
testcase_08 AC 122 ms
98,756 KB
testcase_09 AC 116 ms
92,880 KB
testcase_10 AC 119 ms
94,776 KB
testcase_11 AC 99 ms
80,108 KB
testcase_12 AC 97 ms
77,696 KB
testcase_13 AC 103 ms
83,332 KB
testcase_14 AC 101 ms
80,820 KB
testcase_15 AC 111 ms
89,636 KB
testcase_16 AC 113 ms
91,872 KB
testcase_17 AC 107 ms
87,504 KB
testcase_18 AC 100 ms
79,916 KB
testcase_19 AC 115 ms
90,680 KB
testcase_20 AC 118 ms
92,364 KB
testcase_21 AC 111 ms
87,648 KB
testcase_22 AC 111 ms
85,912 KB
testcase_23 AC 106 ms
83,828 KB
testcase_24 AC 102 ms
78,840 KB
testcase_25 AC 106 ms
82,304 KB
testcase_26 AC 114 ms
90,220 KB
testcase_27 AC 114 ms
90,372 KB
testcase_28 AC 103 ms
81,480 KB
testcase_29 AC 130 ms
102,672 KB
testcase_30 AC 121 ms
95,696 KB
testcase_31 AC 105 ms
80,588 KB
testcase_32 AC 103 ms
79,892 KB
testcase_33 AC 106 ms
84,512 KB
testcase_34 AC 122 ms
98,428 KB
testcase_35 AC 110 ms
86,948 KB
testcase_36 AC 120 ms
95,968 KB
testcase_37 AC 130 ms
102,428 KB
testcase_38 AC 98 ms
78,776 KB
testcase_39 AC 113 ms
88,480 KB
testcase_40 AC 120 ms
95,764 KB
testcase_41 AC 97 ms
77,588 KB
testcase_42 AC 102 ms
78,172 KB
testcase_43 AC 88 ms
71,528 KB
testcase_44 AC 90 ms
71,524 KB
testcase_45 AC 90 ms
71,552 KB
testcase_46 AC 91 ms
71,524 KB
testcase_47 AC 90 ms
71,772 KB
testcase_48 AC 89 ms
71,416 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input = sys.stdin.readline
from collections import *

N, K = map(int, input().split())
A = list(map(int, input().split()))
s = set()
s.add(0)
now = 0

for Ai in A:
    now ^= Ai
    
    if now^K in s:
        print('Yes')
        exit()
    
    s.add(now)

print('No')
0