keys = ['red', 'green', 'blue'] values = ['#FF0000','#008000', '#0000FF'] color_dictionary = dict(zip(keys, values)) print(color_dictionary)
python 使用两个列表合成字典
猜你喜欢
转载自www.cnblogs.com/sea-stream/p/9981747.html
今日推荐
周排行