summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
Diffstat (limited to 'Doc')
-rw-r--r--Doc/library/itertools.rst4
1 files changed, 2 insertions, 2 deletions
diff --git a/Doc/library/itertools.rst b/Doc/library/itertools.rst
index 1eb554a..7099fa0 100644
--- a/Doc/library/itertools.rst
+++ b/Doc/library/itertools.rst
@@ -705,9 +705,9 @@ which incur interpreter overhead.
next(b, None)
return zip(a, b)
- def grouper(n, iterable, fillvalue=None):
+ def grouper(iterable, n, fillvalue=None):
"Collect data into fixed-length chunks or blocks"
- # grouper(3, 'ABCDEFG', 'x') --> ABC DEF Gxx"
+ # grouper('ABCDEFG', 3, 'x') --> ABC DEF Gxx"
args = [iter(iterable)] * n
return zip_longest(*args, fillvalue=fillvalue)