n,k = map(int,input().split()) *a, = map(int,input().split()) g = 0 for ai in a: g ^= ai%k print("YES" if g else "NO")