random — Pseudorandom Number Generators — PyMOTW 3
The random module provides a fast pseudorandom number generator based on the Mersenne Twister algorithm. Originally developed to produce inputs for Monte Carlo simulations, Mersenne Twister generates numbers with nearly uniform distribution and a large period, making it suited for a wide range of applications.
This post is part of the Python Module of the Week series for Python 3. See PyMOTW.com for more articles from the series.