#include // debug #ifdef LOCAL #include #define debug(...) debug_print::multi_print(#__VA_ARGS__, __VA_ARGS__) #else #define debug(...) (static_cast(0)) #endif // #include "atcoder/all" using namespace std; using ll = long long; using ld = long double; void solve() { int n, x; cin >> n >> x; vector v(n); for (int i = 0; i < n; i++) { cin >> v[i]; } sort(v.begin(), v.end(), [x](int a, int b) { return min(a, a ^ x) < min(b, b ^ x); }); debug(v); bool ok = true; for (int i = 0; i < n - 1; i++) { ok &= v[i] < (v[i + 1] ^ x); ok &= (v[i] ^ x) < v[i + 1]; } cout << (ok ? "Yes" : "No") << endl; } int main() { ios::sync_with_stdio(false); cin.tie(nullptr); int t = 1; // cin >> t; while (t--) { solve(); } return 0; }