JSON list of dictionaries to python -
my json file list of dictionaries
i able open not sure how access "the_dict" dictionary can retrieve , print "test" , "pie" in python program.
with open('my_settings.json') json_data: config = json.load(json_data) # my_words = config["the_dict"] tried not work
config_file
list, not dictionary, have observed. need access first dictionary in list, , call key "the_dict"
"words"
list of words:
my_words = config_file[0]["the_dict"]["words"]
Comments
Post a Comment