Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
Second solution in Creative category for Compress List by eugene100372
from typing import Iterable
from itertools import groupby
def compress(items: list) -> Iterable:
return [next(group) for key, group in groupby(items)]
Jan. 28, 2021