結果

問題 No.2298 yukicounter
ユーザー Navier_BoltzmannNavier_Boltzmann
提出日時 2023-05-18 22:08:18
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 280 ms / 2,000 ms
コード長 464 bytes
コンパイル時間 192 ms
コンパイル使用メモリ 82,036 KB
実行使用メモリ 159,848 KB
最終ジャッジ日時 2024-12-16 10:37:04
合計ジャッジ時間 3,981 ms
ジャッジサーバーID
(参考情報)
judge4 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 30
権限があれば一括ダウンロードができます

ソースコード

diff #

from collections import *
from itertools import *
from heapq import *
from functools import *
import sys,math
input = sys.stdin.readline

S = list(input())[:-1]
N = len(S)
X = list('yukicoder')
now = 0
ans = []
while now < N-8:
    if all(S[now+j]==X[j] for j in range(9)):
        ans.append('*')
        now += 9
    else:
        ans.append(S[now])
        now += 1

res = 0
for g,r in groupby(ans):
    if g=='*':
        res = max(res,len(list(r)))
print(res)
0