@bitloops/bl-transpiler
Version:
The one and only Bitloops Language transpiler
12 lines • 415 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.RandomUtils = void 0;
class RandomUtils {
static getRandomIntWithNumberOfDigits(digits) {
const min = Math.pow(10, digits - 1);
const max = Math.pow(10, digits) - 1;
return Math.floor(Math.random() * (max - min) + min);
}
}
exports.RandomUtils = RandomUtils;
//# sourceMappingURL=RandomUtils.js.map