結果
| 問題 |
No.3342 AAB Game
|
| コンテスト | |
| ユーザー |
回転
|
| 提出日時 | 2025-11-13 22:08:54 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 230 bytes |
| コンパイル時間 | 304 ms |
| コンパイル使用メモリ | 82,412 KB |
| 実行使用メモリ | 59,744 KB |
| 最終ジャッジ日時 | 2025-11-13 22:08:58 |
| 合計ジャッジ時間 | 3,498 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 24 WA * 15 |
ソースコード
N = int(input())
S = input()
if("B" not in S):
print("Bob")
exit()
if("AA" in S):
print("Alice")
exit()
S = S[::-1]
SUM = 0
for i in range(N):
SUM += i * (S[i] == "A")
print("Alice" if SUM%2 == 1 else "Bob")
回転