Sunday, December 5, 2010

reverse a list with slicing

>>> [1,2,3][::-1]

[3, 2, 1]

No comments:

Post a Comment