...
MSC30-C. Do not use the rand() function for generating pseudorandom numbers addresses PRNGs from a different perspective, which is the cycle of the pseudorandom number sequence—that is, during a single run of a PRNG, the time interval after which the PRNG generates the same random numbers. MSC30-C deprecates disallows use of the rand()
function because it generates numbers that have a comparatively short cycle. The same rule proposes the use of the random()
function for POSIX and the CryptGenRandom()
function for Windows.
...