3 ms·
> doesn't do list.sort(), it's still sorted(list). WHY???? Because sorted() is a non-destructive sorting - it returns a new list.
by lngnmn 10y ago
> doesn't do list.sort(), it's still sorted(list). WHY????
Because sorted() is a non-destructive sorting - it returns a new list.