json into a dict? no sweat! for how to put json data into a dictionary python, just use json.loads() if it’s a string.
for files:
```python
import json
data = json.load(open('file.json'))
```
but tbh, using `with` is safer (like others said).
ps. if you’re getting errors, maybe your json is malformed. double-check it!
for files:
```python
import json
data = json.load(open('file.json'))
```
but tbh, using `with` is safer (like others said).
ps. if you’re getting errors, maybe your json is malformed. double-check it!
