MCPcopy Create free account
hub / github.com/Vishal-raj-1/Awesome-JavaScript-Projects / random

Function random

assets/js/block_ninja.js:224–224  ·  view source on GitHub ↗
(min, max)

Source from the content-addressed store, hash-verified

222
223// Generates a random number between min (inclusive) and max (exclusive)
224const random = (min, max) => Math.random() * (max - min) + min;
225
226// Generates a random integer between and possibly including min and max values
227const randomInt = (min, max) => ((Math.random() * (max - min + 1)) | 0) + min;

Callers 3

block_ninja.jsFile · 0.70
addSparkFunction · 0.70
glueShedSparksFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected