This is something that I have to do every once in a while and can never remember the method. To save myself some time, I've written this here in hope that I can remember it next time.
student_tuples = [
('john', 'A', 15),
('jane', 'B', 12),
('dave', 'B', 10),
# sort by age
sorted(student_tuples, key = lambda student: student)
[('dave', 'B', 10), ('jane', 'B', 12), ('john', 'A', 15)]
This great example is straight from the Python wiki page.
[ Source ]