import randomInteger from "random-int";
// min 10 & max 5. Shouldn't it throw an error?
const number = randomInteger(10, 5);
console.log(number);
Always gives a 6/7/8/9, which is understandable, but not what I expected.
I did a simple check for all the possible results like:
import randomInteger from "random-int";
const number = (times = 1000) =>
Array.from({ length: times }).map(() => randomInteger(10, 5));
console.log(...new Set(number()));
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too