結果
| 問題 |
No.3070 Collecting Coins Speedrun 2
|
| コンテスト | |
| ユーザー |
detteiuu
|
| 提出日時 | 2025-03-21 21:51:09 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 261 bytes |
| コンパイル時間 | 318 ms |
| コンパイル使用メモリ | 81,828 KB |
| 実行使用メモリ | 81,964 KB |
| 最終ジャッジ日時 | 2025-03-21 21:51:14 |
| 合計ジャッジ時間 | 3,065 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 26 WA * 6 |
ソースコード
N = int(input())
C = list(map(int, input().split()))
MOD = 998244353
if 0 <= C[0] and 0 <= C[-1]:
print(pow(2, N-1, MOD))
elif C[0] < 0 and C[-1] < 0:
print(pow(2, N-1, MOD))
elif 0 in C:
print(pow(2, N-2, MOD)*3)
else:
print(pow(2, N-1, MOD))
detteiuu