RANDOM NUMBER GENERATORS
Random numbers are essential to a wide range of applications that work with or simulate real-world data. They are used in statistical analysis to facilitate construction of unbiased, representative samples. Random sampling is at the core of many machine learning algorithms. Games and simulations often lean heavily on random numbers, including for generating variety in scenarios and for the artificial intelligence procedures for non-player characters.
In interviews, random number generator problems combine mathematical concepts like statistics with computer code, allowing for evaluation of your analytical skills as well as your coding ability.
Most languages or standard libraries provide a random number generator. These functions are typically more properly referred to as pseudorandom number generators. A pseudorandom number generator produces a sequence of numbers that shares many properties with a true random sequence, but is generated by an algorithm employing...