diff options
| author | Georg Brandl <georg@python.org> | 2008-08-08 06:44:14 +0000 |
|---|---|---|
| committer | Georg Brandl <georg@python.org> | 2008-08-08 06:44:14 +0000 |
| commit | 409c9d7184276df875c884c9220a2e6d0efd997c (patch) | |
| tree | 7ff16e6cc075717620098cd021776ea69ca17c03 /Doc/tutorial | |
| parent | 676cce3b4bb08c724723600952c33e2359230ed1 (diff) | |
| download | cpython-git-409c9d7184276df875c884c9220a2e6d0efd997c.tar.gz | |
#3522: zip() returns an iterator.
Diffstat (limited to 'Doc/tutorial')
| -rw-r--r-- | Doc/tutorial/datastructures.rst | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Doc/tutorial/datastructures.rst b/Doc/tutorial/datastructures.rst index 623986ecd6..a068efd0c7 100644 --- a/Doc/tutorial/datastructures.rst +++ b/Doc/tutorial/datastructures.rst @@ -257,7 +257,7 @@ A more verbose version of this snippet shows the flow explicitly:: In real world, you should prefer builtin functions to complex flow statements. The :func:`zip` function would do a great job for this use case:: - >>> zip(*mat) + >>> list(zip(*mat)) [(1, 4, 7), (2, 5, 8), (3, 6, 9)] See :ref:`tut-unpacking-arguments` for details on the asterisk in this line. |
