@ginden/blinkstick-v2
Version:
Improved Blickstick API for Node.js
17 lines • 588 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.randomIntInclusive = randomIntInclusive;
/**
* Generate a random integer number within a range.
*
* @private
* @static
* @method randomIntInclusive
* @param {Number} low the low value of the number
* @param {Number} high the high value of the number
* @return {Number} Random number in the range of [low..high] inclusive of low and high
*/
function randomIntInclusive(low, high) {
return Math.floor(Math.random() * (high - low + 1) + low);
}
//# sourceMappingURL=random-int-inclusive.js.map