結果

問題 No.1716 Bonus Nim
ユーザー tassei903tassei903
提出日時 2021-10-22 22:00:06
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 605 bytes
コンパイル時間 144 ms
コンパイル使用メモリ 81,836 KB
実行使用メモリ 133,284 KB
最終ジャッジ日時 2023-10-24 13:07:17
合計ジャッジ時間 4,408 ms
ジャッジサーバーID
(参考情報)
judge11 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 33 ms
53,528 KB
testcase_01 AC 34 ms
53,528 KB
testcase_02 AC 34 ms
53,528 KB
testcase_03 AC 34 ms
53,528 KB
testcase_04 AC 124 ms
112,316 KB
testcase_05 AC 124 ms
115,900 KB
testcase_06 AC 122 ms
114,112 KB
testcase_07 AC 117 ms
106,648 KB
testcase_08 AC 118 ms
112,412 KB
testcase_09 AC 127 ms
109,652 KB
testcase_10 AC 118 ms
111,284 KB
testcase_11 AC 123 ms
110,276 KB
testcase_12 AC 117 ms
108,880 KB
testcase_13 AC 143 ms
132,856 KB
testcase_14 AC 126 ms
121,760 KB
testcase_15 AC 182 ms
76,656 KB
testcase_16 WA -
testcase_17 AC 34 ms
53,540 KB
testcase_18 AC 34 ms
53,540 KB
testcase_19 WA -
testcase_20 AC 34 ms
53,540 KB
testcase_21 WA -
testcase_22 AC 129 ms
121,800 KB
testcase_23 AC 126 ms
120,860 KB
testcase_24 AC 121 ms
117,544 KB
testcase_25 AC 132 ms
133,284 KB
testcase_26 AC 127 ms
121,092 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input = lambda :sys.stdin.readline()[:-1]
ni = lambda :int(input())
na = lambda :list(map(int,input().split()))
sys.setrecursionlimit(10**7)
yes = lambda :print("yes");Yes = lambda :print("Yes");YES = lambda : print("YES")
no = lambda :print("no");No = lambda :print("No");NO = lambda : print("NO")
#######################################################################
t = ni()
for _ in range(t):
    n = ni()
    a = na()
    if n%2:
        print("Alice")
        continue
    z = 0
    for i in range(n):
        z^=(a[i]-1)
    if z:
        print("Alice")
    else:
        print("Bob")
0