This commit is contained in:
Phil Borel 2025-02-27 20:04:38 +08:00 committed by GitHub
commit 3264364859
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -42,7 +42,7 @@ class Random {
if (seed_ > M) { if (seed_ > M) {
seed_ -= M; seed_ -= M;
} }
return seed_; return seed_ - 1;
} }
// Returns a uniformly distributed value in the range [0..n-1] // Returns a uniformly distributed value in the range [0..n-1]
// REQUIRES: n > 0 // REQUIRES: n > 0