Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
1-liner itertools.groupby solution in Clear category for Long Repeat by swagg010164
from itertools import groupby
def long_repeat(line):
return max([len(list(g)) for k, g in groupby(line)]) if line else 0
Dec. 28, 2019
Comments: