結果
| 問題 |
No.341 沈黙の期間
|
| コンテスト | |
| ユーザー |
Fullmoon85072
|
| 提出日時 | 2020-08-03 22:40:53 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
AC
|
| 実行時間 | 39 ms / 5,000 ms |
| コード長 | 286 bytes |
| コンパイル時間 | 389 ms |
| コンパイル使用メモリ | 82,416 KB |
| 実行使用メモリ | 53,504 KB |
| 最終ジャッジ日時 | 2024-09-13 17:36:17 |
| 合計ジャッジ時間 | 1,630 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| 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