結果

問題 No.1506 Unbalanced Pocky Game
ユーザー snrnsidy
提出日時 2021-05-23 00:17:44
言語 C++17
(gcc 13.3.0 + boost 1.87.0)
結果
WA  
実行時間 -
コード長 453 bytes
コンパイル時間 1,786 ms
コンパイル使用メモリ 195,332 KB
最終ジャッジ日時 2025-01-21 17:16:15
ジャッジサーバーID
(参考情報)
judge2 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 38 WA * 25
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>

using namespace std;

int main(void) 
{
    cin.tie(0);
    ios::sync_with_stdio(false); 

    long long int val = 0;
    int n, t;
    vector <long long int> v;

    cin >> n;

    for (int i = 0; i < n; i++)
    {
        cin >> t;
        if (i < n - 1)
        {
            val ^= t;
        }
        v.push_back(t);
    }

    if (val <= v[n-1]) cout << "Alice" << '\n';
    else cout << "Bob" << '\n';

    return 0;
}
0