import std.random, std.range, std.stdio;
void main()
{
foreach (_; 0 .. 100)
{
immutable seed = unpredictableSeed();
writeln(seed, " => ", randomSample(iota(100), 1, Random(seed)).front);
}
}
--------
The random generator is assigned to the Range only after it was primed and
the default constructed random generator always returns the same first value.
Comment #1 by github-bugzilla — 2012-07-22T19:50:32Z