結果

問題 No.1506 Unbalanced Pocky Game
ユーザー mkawa2mkawa2
提出日時 2021-05-14 22:59:22
言語 Python3
(3.11.6 + numpy 1.26.0 + scipy 1.11.3)
結果
AC  
実行時間 70 ms / 2,000 ms
コード長 936 bytes
コンパイル時間 747 ms
コンパイル使用メモリ 10,896 KB
実行使用メモリ 19,184 KB
最終ジャッジ日時 2023-07-25 09:01:04
合計ジャッジ時間 6,018 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 16 ms
7,836 KB
testcase_01 AC 16 ms
7,920 KB
testcase_02 AC 16 ms
7,848 KB
testcase_03 AC 19 ms
8,492 KB
testcase_04 AC 49 ms
10,336 KB
testcase_05 AC 53 ms
10,832 KB
testcase_06 AC 39 ms
9,584 KB
testcase_07 AC 32 ms
9,040 KB
testcase_08 AC 40 ms
9,724 KB
testcase_09 AC 56 ms
10,900 KB
testcase_10 AC 56 ms
10,812 KB
testcase_11 AC 33 ms
9,088 KB
testcase_12 AC 31 ms
9,132 KB
testcase_13 AC 21 ms
8,800 KB
testcase_14 AC 26 ms
9,236 KB
testcase_15 AC 24 ms
9,008 KB
testcase_16 AC 39 ms
10,764 KB
testcase_17 AC 28 ms
9,408 KB
testcase_18 AC 23 ms
8,876 KB
testcase_19 AC 22 ms
9,068 KB
testcase_20 AC 40 ms
10,880 KB
testcase_21 AC 26 ms
9,056 KB
testcase_22 AC 32 ms
9,740 KB
testcase_23 AC 17 ms
7,960 KB
testcase_24 AC 16 ms
7,848 KB
testcase_25 AC 49 ms
11,476 KB
testcase_26 AC 70 ms
19,048 KB
testcase_27 AC 68 ms
19,156 KB
testcase_28 AC 67 ms
18,504 KB
testcase_29 AC 67 ms
18,628 KB
testcase_30 AC 69 ms
19,184 KB
testcase_31 AC 70 ms
19,056 KB
testcase_32 AC 68 ms
18,864 KB
testcase_33 AC 67 ms
18,652 KB
testcase_34 AC 66 ms
18,436 KB
testcase_35 AC 67 ms
18,568 KB
testcase_36 AC 16 ms
7,952 KB
testcase_37 AC 17 ms
7,864 KB
testcase_38 AC 17 ms
7,952 KB
testcase_39 AC 16 ms
7,844 KB
testcase_40 AC 17 ms
7,952 KB
testcase_41 AC 17 ms
7,796 KB
testcase_42 AC 16 ms
7,812 KB
testcase_43 AC 16 ms
7,840 KB
testcase_44 AC 17 ms
7,828 KB
testcase_45 AC 17 ms
7,900 KB
testcase_46 AC 35 ms
11,904 KB
testcase_47 AC 22 ms
9,388 KB
testcase_48 AC 24 ms
9,740 KB
testcase_49 AC 38 ms
12,420 KB
testcase_50 AC 34 ms
11,808 KB
testcase_51 AC 37 ms
12,280 KB
testcase_52 AC 33 ms
11,748 KB
testcase_53 AC 41 ms
13,144 KB
testcase_54 AC 25 ms
9,952 KB
testcase_55 AC 23 ms
9,340 KB
testcase_56 AC 23 ms
9,260 KB
testcase_57 AC 35 ms
11,828 KB
testcase_58 AC 22 ms
9,428 KB
testcase_59 AC 20 ms
8,864 KB
testcase_60 AC 27 ms
10,448 KB
testcase_61 AC 34 ms
12,016 KB
testcase_62 AC 31 ms
11,396 KB
testcase_63 AC 26 ms
10,020 KB
testcase_64 AC 37 ms
12,416 KB
testcase_65 AC 28 ms
10,412 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys

sys.setrecursionlimit(10**6)
int1 = lambda x: int(x)-1
p2D = lambda x: print(*x, sep="\n")
def II(): return int(sys.stdin.buffer.readline())
def LI(): return list(map(int, sys.stdin.buffer.readline().split()))
def LI1(): return list(map(int1, sys.stdin.buffer.readline().split()))
def LLI(rows_number): return [LI() for _ in range(rows_number)]
def LLI1(rows_number): return [LI1() for _ in range(rows_number)]
def BI(): return sys.stdin.buffer.readline().rstrip()
def SI(): return sys.stdin.buffer.readline().rstrip().decode()
# dij = [(0, 1), (-1, 0), (0, -1), (1, 0)]
# dij = [(0, 1), (-1, 0), (0, -1), (1, 0), (1, 1), (1, -1), (-1, 1), (-1, -1)]
dij = [(0, 1), (1, 0), (1, 1), (1, -1)]
inf = 10**16
md = 998244353
# md = 10**9+7

n=II()
aa=LI()
aa.reverse()
for i,a in enumerate(aa):
    if a>1:
        if i&1:print("Bob")
        else:print("Alice")
        break
else:
    if n&1:print("Alice")
    else:print("Bob")
0