結果

問題 No.1506 Unbalanced Pocky Game
ユーザー nasubi24nasubi24
提出日時 2021-05-14 22:23:39
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 81 ms / 2,000 ms
コード長 351 bytes
コンパイル時間 172 ms
コンパイル使用メモリ 82,460 KB
実行使用メモリ 102,408 KB
最終ジャッジ日時 2024-04-10 00:53:04
合計ジャッジ時間 5,261 ms
ジャッジサーバーID
(参考情報)
judge3 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 37 ms
53,332 KB
testcase_01 AC 35 ms
53,356 KB
testcase_02 AC 34 ms
52,988 KB
testcase_03 AC 41 ms
61,264 KB
testcase_04 AC 59 ms
82,748 KB
testcase_05 AC 62 ms
85,828 KB
testcase_06 AC 51 ms
76,540 KB
testcase_07 AC 46 ms
70,948 KB
testcase_08 AC 52 ms
76,072 KB
testcase_09 AC 60 ms
86,388 KB
testcase_10 AC 64 ms
88,388 KB
testcase_11 AC 46 ms
70,872 KB
testcase_12 AC 45 ms
69,744 KB
testcase_13 AC 39 ms
63,304 KB
testcase_14 AC 47 ms
70,516 KB
testcase_15 AC 44 ms
67,480 KB
testcase_16 AC 59 ms
85,536 KB
testcase_17 AC 47 ms
71,884 KB
testcase_18 AC 42 ms
67,332 KB
testcase_19 AC 41 ms
64,340 KB
testcase_20 AC 61 ms
87,888 KB
testcase_21 AC 44 ms
68,000 KB
testcase_22 AC 52 ms
78,540 KB
testcase_23 AC 36 ms
52,864 KB
testcase_24 AC 36 ms
53,108 KB
testcase_25 AC 74 ms
96,844 KB
testcase_26 AC 81 ms
102,104 KB
testcase_27 AC 81 ms
102,028 KB
testcase_28 AC 80 ms
101,960 KB
testcase_29 AC 80 ms
101,356 KB
testcase_30 AC 80 ms
101,964 KB
testcase_31 AC 77 ms
102,196 KB
testcase_32 AC 79 ms
102,408 KB
testcase_33 AC 78 ms
101,600 KB
testcase_34 AC 77 ms
101,480 KB
testcase_35 AC 78 ms
100,596 KB
testcase_36 AC 35 ms
52,628 KB
testcase_37 AC 36 ms
52,436 KB
testcase_38 AC 36 ms
53,348 KB
testcase_39 AC 37 ms
52,264 KB
testcase_40 AC 37 ms
52,892 KB
testcase_41 AC 36 ms
53,496 KB
testcase_42 AC 36 ms
52,944 KB
testcase_43 AC 36 ms
52,608 KB
testcase_44 AC 36 ms
53,152 KB
testcase_45 AC 35 ms
51,872 KB
testcase_46 AC 49 ms
73,816 KB
testcase_47 AC 42 ms
64,012 KB
testcase_48 AC 43 ms
64,676 KB
testcase_49 AC 53 ms
75,252 KB
testcase_50 AC 51 ms
74,584 KB
testcase_51 AC 52 ms
75,484 KB
testcase_52 AC 47 ms
71,252 KB
testcase_53 AC 56 ms
79,444 KB
testcase_54 AC 43 ms
67,152 KB
testcase_55 AC 39 ms
63,144 KB
testcase_56 AC 39 ms
63,372 KB
testcase_57 AC 48 ms
73,272 KB
testcase_58 AC 41 ms
62,680 KB
testcase_59 AC 41 ms
61,864 KB
testcase_60 AC 46 ms
68,100 KB
testcase_61 AC 51 ms
74,344 KB
testcase_62 AC 48 ms
70,564 KB
testcase_63 AC 45 ms
66,044 KB
testcase_64 AC 51 ms
74,652 KB
testcase_65 AC 44 ms
67,392 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n=int(input())
a=list(map(int,input().split()))
cnt=n
for i in range(n):
    if a[i]!=1:
        cnt=i+1
        break
cnt2=n
for i in range(n-1,-1,-1):
    if a[i]!=1:
        cnt2=n-i-1
        break
num=n-cnt
if cnt2==n:
    if n%2==0:
        print("Bob")
    else:
        print("Alice")
elif cnt2%2==0:
    print("Alice")
else:
    print("Bob")
0