#include #include using namespace std; typedef long long ll; #define rep(i, n) for (ll i = 0; i < (n); i++) int main(void) { ll n, k; cin >> n >> k; vector a(n); rep(i, n) { cin >> a[i]; } ll m = 0; rep(i, n) { m ^= a[i] % (k + 1); } cout << (m ? "YES" : "NO") << endl; return 0; }