第40094题 判断题
在with中打开文件时,如果显式关闭文件,将导致异常,因为with将能自动关闭文件,因此下列Python 代码执行将触发异常。 ( )
with open("123.txt", "w") as f:
    for i in range(10):
        print(i, file = f)
f.close()
{{ option.label }}
子题{{ index + 1 }} {{ child.type_label }}
{{ option.label }}
✓ 正确 ◐ 部分正确 ✗ 错误
程序运行统计
暂无判题统计
知识点:
提交{{ questionInfo.stats ? questionInfo.stats.submit_count : 0 }}次 正确率{{ statsAccuracy }}%
答案解析