#include using namespace std; typedef long long ll; ll INFL = 1000000000000000010;//10^18 = 2^60 int INF = 2000000000;//10^9 ll MOD = 998244353; int main() { int N,K; cin >> N >> K; vector A(N); for(int i = 0; i < N; i++) cin >> A.at(i); for(int i = 0; i < N; i++){ A.at(i) %= K+1; } int XOR = A.at(0); for(int i = 1; i < N; i++){ XOR = XOR xor A.at(i); } if(XOR){ cout << "YES" << endl; }else{ cout << "NO" << endl; } }