File tree Expand file tree Collapse file tree 2 files changed +2
-4
lines changed Expand file tree Collapse file tree 2 files changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -178,9 +178,8 @@ Point(x=1, y=2)
178
178
179
179
Iterator
180
180
--------
181
- ** Iterator is any object with next() special method.**
182
181
``` python
183
- < iter > = iter (< collection> ) # Calling `iter(<iter>)` returns the same object.
182
+ < iter > = iter (< collection> )
184
183
< iter > = iter (< function> , to_exclusive) # Sequence of return values until 'to_exclusive'.
185
184
< el> = next (< iter > [, default]) # Raises StopIteration or returns 'default' on end.
186
185
```
Original file line number Diff line number Diff line change @@ -320,8 +320,7 @@ <h2 id="namedtuple"><a href="#namedtuple" name="namedtuple">#</a>Named Tuple</h2
320
320
(< span class ="hljs-string "> 'x'</ span > , < span class ="hljs-string "> 'y'</ span > )
321
321
</ code > </ pre >
322
322
< h2 id ="iterator "> < a href ="#iterator " name ="iterator "> #</ a > Iterator</ h2 >
323
- < p > < strong > Iterator is any object with next() special method.</ strong > </ p >
324
- < pre > < code class ="python language-python hljs "> <iter> = iter(<collection>) < span class ="hljs-comment "> # Calling `iter(<iter>)` returns the same object.</ span >
323
+ < pre > < code class ="python language-python hljs "> <iter> = iter(<collection>)
325
324
<iter> = iter(<function>, to_exclusive) < span class ="hljs-comment "> # Sequence of return values until 'to_exclusive'.</ span >
326
325
<el> = next(<iter> [, default]) < span class ="hljs-comment "> # Raises StopIteration or returns 'default' on end.</ span >
327
326
</ code > </ pre >
You can’t perform that action at this time.
0 commit comments