⬅︎ Back to Fastest way to uniqify a list in Python
Returns a unique list, sorted. (Speed is medium.)[a for a,b in itertools.groupby(sorted(seq))]It's f12 in the results below:* f5 90.08* f5b 87.62* f8 15.004* f10 56.096* f11 59.153f1 5.546f3 21.098f6 31.611f7 3.47f9 4.584f12 25.881
Comment
Returns a unique list, sorted. (Speed is medium.)
[a for a,b in itertools.groupby(sorted(seq))]
It's f12 in the results below:
* f5 90.08
* f5b 87.62
* f8 15.004
* f10 56.096
* f11 59.153
f1 5.546
f3 21.098
f6 31.611
f7 3.47
f9 4.584
f12 25.881