]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-111343: Fix `itertools` docs: `start` arg is optional for `count` (gh-111344)
authorNikita Sobolev <mail@sobolevn.me>
Fri, 27 Oct 2023 04:30:13 +0000 (07:30 +0300)
committerGitHub <noreply@github.com>
Fri, 27 Oct 2023 04:30:13 +0000 (04:30 +0000)
Doc/library/itertools.rst

index 5846d784c88cccd6db7869ae49e7c84ba5ed2af9..f97e7f720ae4e492803274afadac404371aea9de 100644 (file)
@@ -41,7 +41,7 @@ operator can be mapped across two vectors to form an efficient dot-product:
 ==================  =================       =================================================               =========================================
 Iterator            Arguments               Results                                                         Example
 ==================  =================       =================================================               =========================================
-:func:`count`       start, [step]           start, start+step, start+2*step, ...                            ``count(10) --> 10 11 12 13 14 ...``
+:func:`count`       [start[, step]]         start, start+step, start+2*step, ...                            ``count(10) --> 10 11 12 13 14 ...``
 :func:`cycle`       p                       p0, p1, ... plast, p0, p1, ...                                  ``cycle('ABCD') --> A B C D A B C D ...``
 :func:`repeat`      elem [,n]               elem, elem, elem, ... endlessly or up to n times                ``repeat(10, 3) --> 10 10 10``
 ==================  =================       =================================================               =========================================