students=[
{"sno":245,"sname":"小李","sgrade":98},
{"sno":252,"sname":"小林","sgrade":77},
{"sno":203,"sname":"小青","sgrade":89},
{"sno":204,"sname":"小吴","sgrade":76}]
students_sort=sorted(students,key=lambda x:x["sgrade"],reverse=True)
print("排序前:")
print(students)
print("排序后:")
print(students_sort)
10-23
2905
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)