lemire / fastrand

Fast random number generation in an interval in Python: Up to 10x faster than random.randint.
Apache License 2.0
88 stars 13 forks source link

Enhancment: Add option for bounded randoms such randint in numpy and python.random #15

Closed ndragon798 closed 1 year ago

ndragon798 commented 2 years ago

Add an option to specify a lower bound for the random int generation. Examples from numpy and the random lib in python below.

numpy.random.randint(950, 1000) random.randint(100,1000)

This would make fastrand a better replacement for quickly generating random ints.

lemire commented 2 years ago

Pull request invited !

lemire commented 1 year ago

Should be fixed in release 1.8.0