Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
Second solution in Creative category for Long Repeat by juestr
def long_repeat(line):
prev, count, m = None, 0, 0
for x in line:
count = x != prev or count + 1
prev, m = x, max(m, count)
return m
June 12, 2019
Comments: