字符串转为字典
import astline=input()linedict=ast.literal_eval(line)
遍历字典
for key in linedict: value=linedict[key]