diff options
author | Raymond Hettinger <rhettinger@users.noreply.github.com> | 2020-08-01 08:18:26 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-08-01 08:18:26 (GMT) |
commit | 5c3270939c09e4c8e80fd26449b718a998701912 (patch) | |
tree | fd4db3e8ecd068c0feaee855d3c53aacb07bb8a9 /Lib/random.py | |
parent | cadda52d974937069eeebea1cca4229e2bd400df (diff) | |
download | cpython-5c3270939c09e4c8e80fd26449b718a998701912.zip cpython-5c3270939c09e4c8e80fd26449b718a998701912.tar.gz cpython-5c3270939c09e4c8e80fd26449b718a998701912.tar.bz2 |
bpo-41421: Algebraic simplification for random.paretovariate() (GH-21695)
Diffstat (limited to 'Lib/random.py')
-rw-r--r-- | Lib/random.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/random.py b/Lib/random.py index a6454f5..37f7111 100644 --- a/Lib/random.py +++ b/Lib/random.py @@ -749,7 +749,7 @@ class Random(_random.Random): # Jain, pg. 495 u = 1.0 - self.random() - return 1.0 / u ** (1.0 / alpha) + return u ** (-1.0 / alpha) def weibullvariate(self, alpha, beta): """Weibull distribution. |