結果

問題 No.1506 Unbalanced Pocky Game
ユーザー MtSaka
提出日時 2021-05-14 22:12:27
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
WA  
実行時間 -
コード長 816 bytes
コンパイル時間 2,769 ms
コンパイル使用メモリ 181,336 KB
実行使用メモリ 6,948 KB
最終ジャッジ日時 2024-10-02 01:30:17
合計ジャッジ時間 5,591 ms
ジャッジサーバーID
(参考情報)
judge4 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 1 WA * 2
other AC * 24 WA * 39
権限があれば一括ダウンロードができます

ソースコード

diff #

//GIVE ME AC!!!!!!!!!!!!!!!!!
#pragma GCC target("avx")
#pragma GCC optimize("O3")
#pragma GCC optimize("unroll-loops")
#include<bits/stdc++.h>
#define ll long long
#define floatset() fixed<<setprecision(15)
#define all(n) n.begin(),n.end()
#define rall(n) n.rbegin(),n.rend()
#define rep(i, s, n) for (ll i = s; i < (ll)(n); i++)
using namespace std;
const int dx[4] = {1, 0, -1, 0};
const int dy[4] = {0, 1, 0, -1};
const ll inf =1e18;
const ll MOD=1000000007;
const ll mod=998244353;
const double pi=acos(-1);
using P=pair<ll,ll>;
int main(){
    ll ans=1;
    ll n;
    cin>>n;
    ll a[n];
    rep(i,0,n){
        cin>>a[i];
    }
    for(ll i=n-1;i>=0;i--){
        if(a[i]==1){
            ans=1-ans;
        }
    }
    if(ans){
        cout<<"Alice"<<endl;
    }
    else{
        cout<<"Bob"<<endl;
    }
}
0