結果

問題 No.2024 Xer
ユーザー mkawa2mkawa2
提出日時 2022-07-29 22:57:09
言語 PyPy3
(7.3.13)
結果
AC  
実行時間 428 ms / 2,000 ms
コード長 1,024 bytes
コンパイル時間 291 ms
コンパイル使用メモリ 86,996 KB
実行使用メモリ 120,420 KB
最終ジャッジ日時 2023-09-26 22:28:46
合計ジャッジ時間 11,106 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 67 ms
71,444 KB
testcase_01 AC 73 ms
71,432 KB
testcase_02 AC 70 ms
71,364 KB
testcase_03 AC 67 ms
71,260 KB
testcase_04 AC 72 ms
71,124 KB
testcase_05 AC 72 ms
71,116 KB
testcase_06 AC 74 ms
71,516 KB
testcase_07 AC 409 ms
106,180 KB
testcase_08 AC 177 ms
120,420 KB
testcase_09 AC 398 ms
120,324 KB
testcase_10 AC 188 ms
120,420 KB
testcase_11 AC 162 ms
89,876 KB
testcase_12 AC 234 ms
102,268 KB
testcase_13 AC 258 ms
101,044 KB
testcase_14 AC 382 ms
119,736 KB
testcase_15 AC 210 ms
96,444 KB
testcase_16 AC 300 ms
99,756 KB
testcase_17 AC 190 ms
93,968 KB
testcase_18 AC 183 ms
93,792 KB
testcase_19 AC 390 ms
119,824 KB
testcase_20 AC 253 ms
100,084 KB
testcase_21 AC 414 ms
120,060 KB
testcase_22 AC 402 ms
120,172 KB
testcase_23 AC 417 ms
120,324 KB
testcase_24 AC 428 ms
120,336 KB
testcase_25 AC 76 ms
75,064 KB
testcase_26 AC 78 ms
76,796 KB
testcase_27 AC 79 ms
76,576 KB
testcase_28 AC 74 ms
75,268 KB
testcase_29 AC 79 ms
76,524 KB
testcase_30 AC 80 ms
76,828 KB
testcase_31 AC 82 ms
76,680 KB
testcase_32 AC 84 ms
76,712 KB
testcase_33 AC 78 ms
76,796 KB
testcase_34 AC 73 ms
75,240 KB
testcase_35 AC 68 ms
71,540 KB
testcase_36 AC 83 ms
76,664 KB
testcase_37 AC 85 ms
76,628 KB
testcase_38 AC 84 ms
76,796 KB
testcase_39 AC 69 ms
71,108 KB
testcase_40 AC 73 ms
75,288 KB
testcase_41 AC 81 ms
76,672 KB
testcase_42 AC 81 ms
76,788 KB
testcase_43 AC 80 ms
76,688 KB
testcase_44 AC 82 ms
76,712 KB
testcase_45 AC 328 ms
100,676 KB
testcase_46 AC 131 ms
83,280 KB
testcase_47 AC 263 ms
101,208 KB
testcase_48 AC 68 ms
71,252 KB
testcase_49 AC 68 ms
71,072 KB
testcase_50 AC 70 ms
71,364 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys

# sys.setrecursionlimit(200005)
int1 = lambda x: int(x)-1
pDB = lambda *x: print(*x, end="\n", file=sys.stderr)
p2D = lambda x: print(*x, sep="\n", end="\n\n", file=sys.stderr)
def II(): return int(sys.stdin.readline())
def LI(): return list(map(int, sys.stdin.readline().split()))
def LLI(rows_number): return [LI() for _ in range(rows_number)]
def LI1(): return list(map(int1, sys.stdin.readline().split()))
def LLI1(rows_number): return [LI1() for _ in range(rows_number)]
def SI(): return sys.stdin.readline().rstrip()
# dij = [(0, 1), (-1, 0), (0, -1), (1, 0)]
# dij = [(0, 1), (-1, 0), (0, -1), (1, 0), (1, 1), (1, -1), (-1, 1), (-1, -1)]
dij = [(-1, 1), (-1, 0), (-1, -1), (1, -1), (1, 1)]
inf = (1 << 63)-1
# inf = (1 << 31)-1
# md = 10**9+7
md = 998244353

n, x = LI()
aa = LI()
ab = []
for a in aa:
    ab.append((a, a ^ x))

ab.sort(key=lambda x: min(x))

def ng():
    print("No")
    exit()

for i in range(n-1):
    if ab[i][0] >= ab[i+1][1]: ng()
    if ab[i][1] >= ab[i+1][0]: ng()

print("Yes")
0