This commit is contained in:
qianhao.xu
2024-01-04 09:01:03 +08:00
parent 8935a6ff97
commit b8f030b68b
436 changed files with 43639 additions and 15 deletions

View File

@@ -0,0 +1,10 @@
function random(min, max) {
if (min >= 0 && max > 0 && max >= min) {
let gab = max - min + 1;
return Math.floor(Math.random() * gab + min);
} else {
return 0;
}
}
export default random;