結果
問題 |
No.2813 Cookie
|
ユーザー |
|
提出日時 | 2024-07-17 23:54:24 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 794 bytes |
コンパイル時間 | 1,817 ms |
コンパイル使用メモリ | 195,792 KB |
最終ジャッジ日時 | 2025-02-23 16:06:44 |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 1 |
other | AC * 5 WA * 25 |
ソースコード
#include <bits/stdc++.h> #pragma GCC target("avx2") #pragma GCC optimize("O3") #pragma GCC optimize("unroll-loops") using namespace std; using ll = long long; const ll mod = 998244353; #define fi first #define se second #define rep(i,n) for(ll i=0;i<n;i++) #define all(x) x.begin(),x.end() #define faster ios::sync_with_stdio(false);cin.tie(nullptr) int main() { ll T; cin >> T; while(T--){ ll N; cin >> N; ll ans=0; rep(i,N){ ll a; cin >> a; a=(a+1)/2; if(a==1){ ans^=(1); }else{ ans^=(2*a-2); } } if(ans!=0){ cout << "Alice" << endl; }else{ cout << "Bob" << endl; } } return 0; }