#include using namespace std; using i64 = long long; #define rep(i,s,e) for(int (i) = (s);(i) <= (e);(i)++) int N; int K; vector a; int main(){ cin >> N >> K; a.resize(N); rep(i,0,N - 1) cin >> a[i]; i64 nim = 0; rep(i,0,N - 1) nim ^= (a[i]) % (K + 1); if(nim == 0){ cout << "NO" << endl; } else{ cout << "YES" << endl; } }