Use a 'with' statement for safe file handling
with open(filename, 'r') as file: # Load the JSON data from the file into a Python object data = json.load(file)
with open(filename, 'r') as file: # Load the JSON data from the file into a Python object data = json.load(file)
本文档使用 WanXiangYunDang 构建