N,K = map(int,input().split()) lsA = list(map(int,input().split())) ans = 0 for i in range(N): ans ^= lsA[i]%(K+1) print('NO' if ans==0 else 'YES')