N,K = map(int,input().split()) A = list(map(int,input().split())) XORA = [A[0]] for i in range(1,N): XORA.append(XORA[-1]^A[i]) SXORA = set(XORA) if K in SXORA: print('Yes') exit() TEMP = 0 for i in range(N): TEMP = TEMP ^ A[i] if K^TEMP in SXORA: print('Yes') exit() print('No')