A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2012-July/120906.html below:

[Python-Dev] cpython: Issue 15265: document the exception raised for invalid sample sizes.

[Python-Dev] cpython: Issue 15265: document the exception raised for invalid sample sizes. [Python-Dev] cpython: Issue 15265: document the exception raised for invalid sample sizes.Georg Brandl g.brandl at gmx.net
Mon Jul 9 12:21:29 CEST 2012
On 09.07.2012 01:02, raymond.hettinger wrote:
> http://hg.python.org/cpython/rev/72174d8af3ba
> changeset:   78015:72174d8af3ba
> user:        Raymond Hettinger <python at rcn.com>
> date:        Sun Jul 08 16:01:53 2012 -0700
> summary:
>    Issue 15265: document the exception raised for invalid sample sizes.
>
> files:
>    Doc/library/random.rst |  3 +++
>    1 files changed, 3 insertions(+), 0 deletions(-)
>
>
> diff --git a/Doc/library/random.rst b/Doc/library/random.rst
> --- a/Doc/library/random.rst
> +++ b/Doc/library/random.rst
> @@ -150,6 +150,9 @@
>      argument.  This is especially fast and space efficient for sampling from a large
>      population:  ``sample(range(10000000), 60)``.
>
> +   If the sample size is larger than the population size, a :exc:``ValueError``

Should be :exc:`ValueError` (one set of quotes only).

Georg

More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4