[Solved] How to sort a list by dict values in Python? [closed]
[ad_1] You could use sorted. The following solution works, provided the value of ‘id’ starts with a single character followed by numbers. sorted(b, key=lambda x: int(x[‘id’][1:])) 1 [ad_2] solved How to sort a list by dict values in Python? [closed]