UNPKG

softkave-js-utils

Version:

JavaScript & Typescript utility functions, types, and classes

7 lines 277 B
export function getRandomIntInclusive(min, max) { min = Math.ceil(min); max = Math.floor(max); // The maximum is inclusive and the minimum is inclusive return Math.floor(Math.random() * (max - min + 1) + min); } //# sourceMappingURL=getRandomIntInclusive.js.map