I’m not satisfied with Math.random() from javascript. I would like to create a function that generates random numbers. What I need is that if I generate 100.000 numbers from 1 to 100, the frequencies that the numbers appear must be as close as possible. The minimum frequency a number appears to be as close as possible to the maximum frequency.
Could you give me some ideas?
I’m not satisfied with Math.random() from javascript. I would like to create a function
Share
You could probably implement MT19937 in JS, which is a quite capable algorithm suitable for a wide range of applications (not cryptography, though!).