Does json.dumps write into file

i mean does it write data to file and is it necessary to use dumps to use loads and what are dumps and loads used for reading or writing

Hi, for that you can you use a codel like this
import json
with open(‘data.json’, ‘w’) as f:
json.dump(data, f)