diff options
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 cd8583fe4a..ef8cb05601 100644 --- a/Lib/random.py +++ b/Lib/random.py @@ -337,7 +337,7 @@ class Random(_random.Random): result[i] = population[j] return result - def choices(self, k, population, weights=None, *, cum_weights=None): + def choices(self, population, weights=None, *, cum_weights=None, k=1): """Return a k sized list of population elements chosen with replacement. If the relative weights or cumulative weights are not specified, |