> In <http://marc.info/?l=openbsd-tech&m=126562459427981&w=1>, > Janne Johansson <jj () it ! su ! se> wrote > [[about rand(3)]] > > The weird part of this (I think) for us outside viewers is that rand() > > has been known to be really poor at random for a long time. Not "a few > > years", but like 20+ years and more. > > Much more: its flaws (including the low-order K bits being periodic > with a period which is <= 2^K) were already documented in Knuth volume 2's > 1st edition, whose copyright date was 1969.
Focusing on the bit problems is irrelevant. Because rand() has srand(), of course it has to have a predictable sequences. Real randomness cannot be built on top of pre-seeded subsystem with those requirements. But it is standardized, and has to work that way, so ours works as required.