I need to quickly compute uniformly distributed n
-th pseudo-random number in range [a, b] without storing any state information.
I.e., computation should depend only on a
, b
, and n
(and possibly seed
) input parameters and should not keep any internal state.
The quality of the randomness does not need to be good.
How can I do it?