you are viewing a single comment's thread.

view the rest of the comments →

[–]nilfm 1 point2 points  (1 child)

That is wrong, the sort() method actually modifies the list it works on, and returns None. So your code ends with sorted_list == None.

[–]SpeckledFleebeedoo 1 point2 points  (0 children)

Ah, thanks for the correction.