python字典排序,按key和value都行

dict(sorted(dic.items(),key=lambda x:x[1]))
posted @ 2022-06-02 10:35  笨笨和呆呆  阅读(20)  评论(0)    收藏  举报