Qrand() is this just a wrapper for rand()? Does it have the same limitations?
-
I couldn't find a page that talked about qrand() or sqrand() . So I'm asking here if it just wraps the functions and has same limitations?
For example srand() and rand() will always product the same numbers given the same seed. Also it only has 0 - RAND_MAX ( which is usually around 35k)
Which makes it a rather poor random number generator without some extra work, like building a larger value out of just the first byte of the int returned by rand. But that's another story.
Is there any other options in QT? If not I'll just do what I said above and build larger data types out of the values returned.
-
-