Skip to content

Commit 4b197f3

Browse files
committed
cleaning more stuff
1 parent 0802c91 commit 4b197f3

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

advanced/iters.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,9 @@ i
5050
>>>
5151
```
5252

53-
We can also iterate over [files](../basics/files.md), but they change
54-
when we do that. They remember their position, so if we iterate over
55-
them twice we get the content once only.
53+
We can also iterate over [files](../basics/files.md), but they remember
54+
their position and we get the content once only if we iterate over them
55+
twice.
5656

5757
```py
5858
>>> with open('test.txt', 'w') as f:
@@ -98,7 +98,8 @@ before, and it actually remembers its position also:
9898
Iterators can only be used once, so we need to create a new iterator if
9999
we want to do another for loop.
100100

101-
Here's a picture that might explain this better:
101+
All iterators are iterables, but not all iterables are iterators. Like
102+
this:
102103

103104
![Iterables and iterators.](../images/iters.png)
104105

0 commit comments

Comments
 (0)