summaryrefslogtreecommitdiffstats
path: root/Doc/library
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2009-01-18 13:24:10 (GMT)
committerGeorg Brandl <georg@python.org>2009-01-18 13:24:10 (GMT)
commit9f7fb849dfbb8e54f1da637c086cd0433f5b7169 (patch)
tree2a4b74bdbf0e7506dfa4464859fd0c59dcb2be56 /Doc/library
parent60e79ced94c84937f31f53f92bc7e85a403eb002 (diff)
downloadcpython-9f7fb849dfbb8e54f1da637c086cd0433f5b7169.zip
cpython-9f7fb849dfbb8e54f1da637c086cd0433f5b7169.tar.gz
cpython-9f7fb849dfbb8e54f1da637c086cd0433f5b7169.tar.bz2
#4979: correct result range for some random functions.
Diffstat (limited to 'Doc/library')
-rw-r--r--Doc/library/random.rst19
1 files changed, 10 insertions, 9 deletions
diff --git a/Doc/library/random.rst b/Doc/library/random.rst
index 63c4bc7..9e55665 100644
--- a/Doc/library/random.rst
+++ b/Doc/library/random.rst
@@ -188,13 +188,13 @@ be found in any statistics text.
.. function:: uniform(a, b)
- Return a random floating point number *N* such that ``a <= N < b`` for
- ``a <= b`` and ``b <= N < a`` for ``b < a``.
+ Return a random floating point number *N* such that ``a <= N <= b`` for
+ ``a <= b`` and ``b <= N <= a`` for ``b < a``.
.. function:: triangular(low, high, mode)
- Return a random floating point number *N* such that ``low <= N < high`` and
+ Return a random floating point number *N* such that ``low <= N <= high`` and
with the specified *mode* between those bounds. The *low* and *high* bounds
default to zero and one. The *mode* argument defaults to the midpoint
between the bounds, giving a symmetric distribution.
@@ -204,8 +204,8 @@ be found in any statistics text.
.. function:: betavariate(alpha, beta)
- Beta distribution. Conditions on the parameters are ``alpha > 0`` and ``beta >
- 0``. Returned values range between 0 and 1.
+ Beta distribution. Conditions on the parameters are ``alpha > 0`` and
+ ``beta > 0``. Returned values range between 0 and 1.
.. function:: expovariate(lambd)
@@ -219,14 +219,15 @@ be found in any statistics text.
.. function:: gammavariate(alpha, beta)
- Gamma distribution. (*Not* the gamma function!) Conditions on the parameters
- are ``alpha > 0`` and ``beta > 0``.
+ Gamma distribution. (*Not* the gamma function!) Conditions on the
+ parameters are ``alpha > 0`` and ``beta > 0``.
.. function:: gauss(mu, sigma)
- Gaussian distribution. *mu* is the mean, and *sigma* is the standard deviation.
- This is slightly faster than the :func:`normalvariate` function defined below.
+ Gaussian distribution. *mu* is the mean, and *sigma* is the standard
+ deviation. This is slightly faster than the :func:`normalvariate` function
+ defined below.
.. function:: lognormvariate(mu, sigma)