I have a sorted list of values i need to filter such that the only values returned are not the same as the value to its left.
For example mylist=[1,2,2,3,3,3,3,6,7,9,9,11] would return [1,2,3,6,7,9,11].
I've done this task using for and if loops but wondering if there is not a more elegant solution using list comprehensions.
Thanks!