1.python 语法对 空格,缩进有严格要求
2.file objects contain a special pair of built-in methods: __enter__()
and__exit__()
such as:
with open("text.txt", "w") as v:
v.write("sss")
1.python 语法对 空格,缩进有严格要求
2.file objects contain a special pair of built-in methods: __enter__()
and__exit__()
such as:
with open("text.txt", "w") as v:
v.write("sss")
转载于:https://www.cnblogs.com/njuzwr/p/4440726.html