lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


> Among many programming circles, rand() is considered harmful.

The Lua manual warns about this. Note that it says that the quality
of math.random() cannot be guaranteed, not that it must be bad.

I seemed to recall that recent glibc had a much better rand() but
I can't find the source of that quote and the glibc sources do not show
a better RNG. (My recollection was that rand() actually was drand48() or
random() but the sources do not show it.)