获取字典的所有key:# !/usr/bin/python3.4 # -*- coding: utf-8 -*- b = { 'video':0, 'music':23 } print(list(b.keys())) # ['music', 'video']