使用两个list创建dict
a = ['math','english','art']
b = ['99','78','66']
c = dict(zip(a,b))
创建指定list为键名的dict
c = {}.fromkeys([keylist],默认值)
使用sorted对字典进行排序,本质上还是sorted函数的使用
sorted(iterable, key=None, reverse=False)
Return a new list containing all items from the iterable in ascending order.
A custom key function can be supplied to customize the sort order, and the
reverse flag can be set to request the result in descending order.
e = sorted(c.items(),key=lambda d : d[0])
e = sorted(c.items(),key=lambda d : d[1])