結果
問題 |
No.1159 Sashiming String
|
ユーザー |
|
提出日時 | 2022-01-27 18:11:31 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 60 ms / 2,000 ms |
コード長 | 171 bytes |
コンパイル時間 | 521 ms |
コンパイル使用メモリ | 81,920 KB |
実行使用メモリ | 60,160 KB |
最終ジャッジ日時 | 2024-12-25 20:46:00 |
合計ジャッジ時間 | 2,134 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 12 |
ソースコード
S = input() counts = 0 counti = 0 for i in range(len(S)-3,-1,-1): if S[i:i+3] == 'ing': counti += 1 if S[i] == "S": counts += counti print(counts)