diff options
Diffstat (limited to 'progs/a129.py')
-rw-r--r-- | progs/a129.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/progs/a129.py b/progs/a129.py new file mode 100644 index 0000000..3d0f600 --- /dev/null +++ b/progs/a129.py @@ -0,0 +1,3 @@ +from itertools import groupby
+def consecutive_duplicates(nums):
+ return [key for key, group in groupby(nums)]
\ No newline at end of file |