[BangPypers] which is better solution of the question

Anand Chitipothu anandology at gmail.com
Wed Jun 17 09:24:45 CEST 2009

> Don't use sorted(..., reverse=True). Instead reverse the list in place
> by using reverse slicing of l[-1::-1], which is about 1.5 times faster.

Why are you using [-1::-1] for reversing? Isn't [::-1] the python
idiom for reversing a list?

More information about the BangPypers mailing list