I have a list of tuples that look something like this:
("Person 1",10)
("Person 2",8)
("Person 3",12)
("Person 4",20)
What I want produced, is the list sorted in ascending order, by the second value of the tuple. So L[0] should be ("Person 2", 8)
after sorting.
How can I do this? Using Python 3.2.2 If that helps.
Question&Answers:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…