結果
| 問題 | No.3458 Scores of Subsequence |
| コンテスト | |
| ユーザー |
sasa8uyauya
|
| 提出日時 | 2026-02-28 19:52:55 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 106 bytes |
| 記録 | |
| コンパイル時間 | 309 ms |
| コンパイル使用メモリ | 78,472 KB |
| 実行使用メモリ | 68,556 KB |
| 最終ジャッジ日時 | 2026-02-28 19:52:59 |
| 合計ジャッジ時間 | 3,648 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | RE * 3 |
| other | RE * 25 |
ソースコード
s=input() M=998244353 m=0 c=0 for i in range(n): if s[i]=="M": m+=1 else: c+=pow(3,m,M)-1 print(c%M)
sasa8uyauya