sort a list of tuples `my_list` by second parameter in the tuple,my_list.sort(key=lambda x: x[1])