We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b75c98f commit 4cc3e84Copy full SHA for 4cc3e84
lectures/python_essentials.md
@@ -332,9 +332,9 @@ We can also use a `with` statement (also known as a [context manager](https://re
332
```{code-cell} python3
333
with open("newfile.txt", "r") as f:
334
file = f.readlines()
335
-with open("output.txt", "w") as fo:
336
- for i, line in enumerate(file):
337
- fo.write(f'Line {i}: {line} \n')
+ with open("output.txt", "w") as fo:
+ for i, line in enumerate(file):
+ fo.write(f'Line {i}: {line} \n')
338
```
339
340
0 commit comments