from collections import * N, K = map(int, input().split()) A = list(map(int, input().split())) Ac = [0] * (N + 1) for i in range(N): Ac[i + 1] = Ac[i] ^ A[i] D = defaultdict(int) for i in range(N + 1): D[Ac[i]] += 1 for i in range(N + 1): D[Ac[i]] -= 1 if D[Ac[i] ^ K]: print("Yes") exit() print("No")