Skip to content

Instantly share code, notes, and snippets.

@felipem775
Created September 12, 2013 08:19
Show Gist options
  • Save felipem775/6534374 to your computer and use it in GitHub Desktop.
Save felipem775/6534374 to your computer and use it in GitHub Desktop.
Using a json file
# Load a json file
json_data=open(jsonFilePath)
data = json.load(json_data)
json_data.close()
# Extract a string value and a array
key1 = data["key1"]
aArray = data["aArray"]
# Elements in a array
for element in aArray:
something(aArray["element"])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment