結果
問題 | No.669 対決!!! 飲み比べ |
ユーザー |
![]() |
提出日時 | 2023-08-25 16:30:46 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 2 ms / 2,000 ms |
コード長 | 474 bytes |
コンパイル時間 | 4,185 ms |
コンパイル使用メモリ | 249,640 KB |
最終ジャッジ日時 | 2025-02-16 13:32:57 |
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 25 |
ソースコード
#include <bits/stdc++.h>#include <atcoder/all>using namespace atcoder;using namespace std;using ll=long long;using ld=long double;ld pie=3.141592653589793;ll mod=998244353;ll inf=1009999999999999990;int main(){ll n,k;cin >> n >> k;vector<ll>a(n);ll z=0;for (ll i = 0; i < n; i++){cin >> a[i];z^=a[i]%(k+1);}if (z==0){cout << "NO" << endl;}else{cout << "YES" << endl;}}