リストの最初の要素に基づいて昇順で並べ替えたいリストのリストがあります。リストの最初の要素が同じである場合は、2番目の要素に基づいて並べ替える必要があります。
これまでのところ、リストの最初の要素のみに基づいて並べ替えることができました。私はそれらをソートするために挿入ソートを使用しました。最初の要素が同じである場合、2番目の要素に基づいてリストを並べ替えるにはどうすればよいですか?
def sort_list ():
    # An example of the list to be sorted
    original_list = [['Glenn', 'Stevens'],
                    ['Phil', 'Wayne'],
                    ['Peter', 'Martin'],
                    ['Phil', 'Turville'],
                    ['Chris', 'Turville']]
    sorted_list = list(original_list)
    for index in range(1, len(sorted_list)):           
        pos = index                                 
        while pos > 0 and sorted_list[pos - 1][0] > sorted_list[pos][0]:    
            sorted_list[pos-1], sorted_list[pos] = sorted_list[pos], sorted_list[pos-1]
            pos -= 1                            
    return sorted_list