結果

問題 No.1716 Bonus Nim
ユーザー tamatotamato
提出日時 2021-10-22 21:33:57
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 455 bytes
コンパイル時間 321 ms
コンパイル使用メモリ 81,940 KB
実行使用メモリ 131,424 KB
最終ジャッジ日時 2023-10-24 12:29:25
合計ジャッジ時間 4,583 ms
ジャッジサーバーID
(参考情報)
judge15 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 36 ms
53,692 KB
testcase_01 AC 36 ms
53,692 KB
testcase_02 AC 36 ms
53,692 KB
testcase_03 AC 36 ms
53,692 KB
testcase_04 AC 123 ms
108,940 KB
testcase_05 AC 130 ms
114,600 KB
testcase_06 AC 123 ms
110,652 KB
testcase_07 AC 122 ms
104,820 KB
testcase_08 AC 121 ms
110,664 KB
testcase_09 AC 127 ms
107,304 KB
testcase_10 AC 119 ms
109,276 KB
testcase_11 AC 128 ms
107,400 KB
testcase_12 AC 122 ms
106,932 KB
testcase_13 AC 141 ms
131,424 KB
testcase_14 AC 129 ms
119,724 KB
testcase_15 AC 171 ms
76,916 KB
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
testcase_19 WA -
testcase_20 WA -
testcase_21 WA -
testcase_22 WA -
testcase_23 WA -
testcase_24 WA -
testcase_25 WA -
testcase_26 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

mod = 1000000007
eps = 10**-9


def main():
    import sys
    input = sys.stdin.readline

    for _ in range(int(input())):
        N = int(input())
        A = list(map(int, input().split()))

        if N & 1:
            print("Alice")
        else:
            g = 0
            for a in A:
                g ^= a
            if g:
                print("Alice")
            else:
                print("Bob")


if __name__ == '__main__':
    main()
0