π"import json" in Python
json = JavaScript Object Notation
import json
# Open the JSON file
with open('data.json') as f:
# Load the JSON data into a Python dictionary
data = json.load(f)
# Access the data as a Python object
print(data['name'])
print(data['age'])Last updated