Untitled

 avatar
unknown
python
a year ago
256 B
8
Indexable
# Criando arquivo json

import json

desafio_json = '''
{
    "name:" "John Smith",
    "age:" 30,
    "city:" "New York",
    "isStudent:" true
    "gpa:" 3.5
}
'''

with open("desafio.json", "w") as arquivo_json:
    json.dump(desafio_json, arquivo_json)
Editor is loading...
Leave a Comment