Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Creative category for Beat The Previous by Buggerman
def beat_previous(digits: str) -> list[int]:
prev, curr = -1, 0
for c in digits:
curr = curr*10 + int(c)
if curr > prev:
yield curr
prev, curr = curr, 0
June 5, 2024