[Python-checkins] bpo-35738: Update the example for timer.Timer.repeat(). (GH-11559)

Miss Islington (bot) webhook-mailer at python.org
Tue Jan 15 05:49:20 EST 2019

commit: 0bb6b891154b5718c2d7604fc4aa7a51a2f9fe70
branch: 3.7
author: Miss Islington (bot) <31488909+miss-islington at users.noreply.github.com>
committer: GitHub <noreply at github.com>
date: 2019-01-15T02:49:16-08:00

bpo-35738: Update the example for timer.Timer.repeat(). (GH-11559)

Show correct number of repeats.
(cherry picked from commit 06f8b57212b2e2cd2e63af36cecdfa3075b324a2)

Co-authored-by: Henry Chen <tahafut at gmail.com>

M Doc/library/timeit.rst

diff --git a/Doc/library/timeit.rst b/Doc/library/timeit.rst
index 93ca940ef5bd..197b8a76fc38 100644
--- a/Doc/library/timeit.rst
+++ b/Doc/library/timeit.rst
@@ -292,7 +292,7 @@ The same can be done using the :class:`Timer` class and its methods::
    >>> t.timeit()
    >>> t.repeat()
-   [0.40193588800002544, 0.3960157959998014, 0.39594301399984033]
+   [0.40183617287970225, 0.37027556854118704, 0.38344867356679524, 0.3712595970846668, 0.37866875250654886]
 The following examples show how to time expressions that contain multiple lines.

More information about the Python-checkins mailing list