📅  最后修改于: 2022-03-11 15:02:16.662000             🧑  作者: Mango
const randomArrayInRange = (min, max, n) => Array.from({ length: n }, () => Math.floor(Math.random() * (max - min + 1)) + min);
// Example
randomArrayInRange(1, 100, 10);