結果
| 問題 | No.341 沈黙の期間 |
| コンテスト | |
| ユーザー |
Fullmoon85072
|
| 提出日時 | 2020-08-03 22:40:53 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
AC
|
| 実行時間 | 27 ms / 5,000 ms |
| コード長 | 286 bytes |
| 記録 | |
| コンパイル時間 | 263 ms |
| コンパイル使用メモリ | 84,736 KB |
| 実行使用メモリ | 51,968 KB |
| 最終ジャッジ日時 | 2026-04-04 06:43:21 |
| 合計ジャッジ時間 | 1,287 ms |
|
ジャッジサーバーID (参考情報) |
judge4_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 11 |
ソースコード
S = input()
max_length = 0
count = 0
prev_ch = ''
for ch in S:
if ch == '…':
count += 1
else:
if prev_ch == '…':
max_length = max(count, max_length)
count = 0
prev_ch = ch
max_length = max(count, max_length)
print(max_length)
Fullmoon85072