python 列表中的字典按某个字段排序

health = sorted(healths, key=lambda k: k['sort'])# healths列表名,sort是字段名
posted @ 2020-07-28 17:30  关美丽  阅读(3679)  评论(0编辑  收藏  举报