summaryrefslogtreecommitdiffstats
path: root/Lib/random.py
diff options
context:
space:
mode:
authorRaymond Hettinger <python@rcn.com>2016-06-25 02:36:42 (GMT)
committerRaymond Hettinger <python@rcn.com>2016-06-25 02:36:42 (GMT)
commit650c1c9ddd2f678c7f6aa86b8f079dce8c1ddef5 (patch)
tree4a92647078debc5f1f9661e84ef630038609ef99 /Lib/random.py
parenta32c4d05312858f2468ad9d7ce53c52c4bcae2b3 (diff)
downloadcpython-650c1c9ddd2f678c7f6aa86b8f079dce8c1ddef5.zip
cpython-650c1c9ddd2f678c7f6aa86b8f079dce8c1ddef5.tar.gz
cpython-650c1c9ddd2f678c7f6aa86b8f079dce8c1ddef5.tar.bz2
Minor beautification
Diffstat (limited to 'Lib/random.py')
-rw-r--r--Lib/random.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/random.py b/Lib/random.py
index 5950735..1cffb0a 100644
--- a/Lib/random.py
+++ b/Lib/random.py
@@ -606,11 +606,11 @@ class Random(_random.Random):
# This version due to Janne Sinkkonen, and matches all the std
# texts (e.g., Knuth Vol 2 Ed 3 pg 134 "the beta distribution").
- y = self.gammavariate(alpha, 1.)
+ y = self.gammavariate(alpha, 1.0)
if y == 0:
return 0.0
else:
- return y / (y + self.gammavariate(beta, 1.))
+ return y / (y + self.gammavariate(beta, 1.0))
## -------------------- Pareto --------------------