結果
| 問題 | No.1534 おなかがいたい |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2021-06-20 19:51:18 |
| 言語 | Python3 (3.14.2 + numpy 2.4.0 + scipy 1.16.3) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 257 bytes |
| 記録 | |
| コンパイル時間 | 779 ms |
| コンパイル使用メモリ | 12,672 KB |
| 実行使用メモリ | 11,264 KB |
| 最終ジャッジ日時 | 2024-06-22 22:34:30 |
| 合計ジャッジ時間 | 2,103 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 17 WA * 2 |
ソースコード
str = input()
p = 0
if "pain" in str:
idx = str.find("pain")
str = str[:idx]
lenS = len(str)
i = 0
while i < lenS:
if str[i : i + 3] == "pon":
p += 1
i += 3
else:
i += 1
print(p - 1)