結果

問題 No.2024 Xer
コンテスト
ユーザー Iroha_3856
提出日時 2026-01-11 16:44:28
言語 C++23
(gcc 15.2.0 + boost 1.89.0)
結果
WA  
実行時間 -
コード長 779 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 3,224 ms
コンパイル使用メモリ 343,024 KB
実行使用メモリ 7,848 KB
最終ジャッジ日時 2026-01-11 16:44:37
合計ジャッジ時間 7,997 ms
ジャッジサーバーID
(参考情報)
judge6 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 42 WA * 5
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

#include <bits/stdc++.h>
using namespace std;
#include <atcoder/modint>
using mint = atcoder::modint998244353;

#define rep(i, l, r) for (int i = (int)(l); i < (int)(r); i++)
#define ll long long
#define all(x) (x).begin(), (x).end()
#define siz(x) (int)x.size()

const int inf = 1e9;
const ll INF = 4e18;

template<class T> bool chmax(T& a, T b) { if (a < b) { a = b; return true; } return false; }
template<class T> bool chmin(T& a, T b) { if (a > b) { a = b; return true; } return false; }

int main() {
    int N, X; cin >> N >> X;
    vector<int> A(N);
    rep(i, 0, N) cin >> A[i];
    int Y = ~X;
    for (int& a : A) a &= Y;
    
    sort(all(A));
    rep(i, 0, N-1) if (A[i] == A[i+1]) {
        cout << "No" << endl;
        return 0;
    }
    cout << "Yes" << endl;
}
0