]> granicus.if.org Git - python/commitdiff
Fix parameter name for enumerate().
authorGeorg Brandl <georg@python.org>
Mon, 12 May 2008 16:53:42 +0000 (16:53 +0000)
committerGeorg Brandl <georg@python.org>
Mon, 12 May 2008 16:53:42 +0000 (16:53 +0000)
Doc/library/functions.rst

index 4232334414500d512131696b49b1a0e100c714ee..bc07d84b02d49eb12c987042dfb3af190f9f405d 100644 (file)
@@ -335,14 +335,15 @@ available.  They are listed here in alphabetical order.
       Using :func:`divmod` with complex numbers is deprecated.
 
 
-.. function:: enumerate(iterable)
-
-   Return an enumerate object. *iterable* must be a sequence, an :term:`iterator`, or some
-   other object which supports iteration.  The :meth:`next` method of the iterator
-   returned by :func:`enumerate` returns a tuple containing a count (from zero) and
-   the corresponding value obtained from iterating over *iterable*.
-   :func:`enumerate` is useful for obtaining an indexed series: ``(0, seq[0])``,
-   ``(1, seq[1])``, ``(2, seq[2])``, .... For example:
+.. function:: enumerate(sequence)
+
+   Return an enumerate object. *sequence* must be a sequence, an
+   :term:`iterator`, or some other object which supports iteration.  The
+   :meth:`next` method of the iterator returned by :func:`enumerate` returns a
+   tuple containing a count (from zero) and the corresponding value obtained
+   from iterating over *iterable*.  :func:`enumerate` is useful for obtaining an
+   indexed series: ``(0, seq[0])``, ``(1, seq[1])``, ``(2, seq[2])``, .... For
+   example:
 
       >>> for i, season in enumerate(['Spring', 'Summer', 'Fall', 'Winter']):
       ...     print i, season