Skip to content

Commit aad929f

Browse files
committed
Fix example
1 parent 08ce2dd commit aad929f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Doc/library/itertools.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -861,7 +861,7 @@ and :term:`generators <generator>` which incur interpreter overhead.
861861

862862
def running_mean(iterable):
863863
"Yield the average of all values seen so far."
864-
# running_mean([8.5, 9.5, 7.5, 7.0]) -> 8.5 9.0 8.5 8.0
864+
# running_mean([8.5, 9.5, 7.5, 6.5]) -> 8.5 9.0 8.5 8.0
865865
return map(truediv, accumulate(iterable), count(1))
866866

867867
def repeatfunc(function, times=None, *args):
@@ -1237,7 +1237,7 @@ and :term:`generators <generator>` which incur interpreter overhead.
12371237
[(0, 'a'), (1, 'b'), (2, 'c')]
12381238

12391239

1240-
>>> list(running_mean([8.5, 9.5, 7.5, 7.0]))
1240+
>>> list(running_mean([8.5, 9.5, 7.5, 6.5]))
12411241
[8.5, 9.0, 8.5, 8.0]
12421242

12431243

0 commit comments

Comments
 (0)