You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The random-number generation facilities we provide are based on rand, which is known to be a low-quality random source. We should switch to using C++11's <random> library to generate random numbers.
(Rationale: In prototyping an assignment that involves generating random objects, the resulting distributions when outcomes depend on correlations between calls to randomInteger are non-uniform. Switching to using std::mt19937 and uniform_int_distribution fixed the issue.
The text was updated successfully, but these errors were encountered:
The random-number generation facilities we provide are based on
rand
, which is known to be a low-quality random source. We should switch to using C++11's<random>
library to generate random numbers.(Rationale: In prototyping an assignment that involves generating random objects, the resulting distributions when outcomes depend on correlations between calls to
randomInteger
are non-uniform. Switching to usingstd::mt19937
anduniform_int_distribution
fixed the issue.The text was updated successfully, but these errors were encountered: