Sam*_*uns 15
像那样:
sorted(your_list, lambda x: int(x.split()[-1]))
Run Code Online (Sandbox Code Playgroud)
eum*_*iro 13
my_list = ['abc 12 34 3333',
'def 21 43 2222',
'fgh 21 43 1111']
my_list.sort(key=lambda x:int(x.split()[-1]))
Run Code Online (Sandbox Code Playgroud)
my_list 就是现在: ['fgh 21 43 1111', 'def 21 43 2222', 'abc 12 34 3333']