MCPcopy Create free account
hub / github.com/cortex-js/compute-engine / rnd

Function rnd

benchmarks/big-decimal/ops-bench.mjs:44–47  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

42// bundles being compared — apples-to-apples arguments).
43let _s = 0x9e3779b9 ^ (prec * 2654435761);
44const rnd = () => {
45 _s = (_s * 1664525 + 1013904223) >>> 0;
46 return _s / 0x100000000;
47};
48const digits = (n) => {
49 let s = '';
50 for (let i = 0; i < n; i++) s += ((rnd() * 10) | 0).toString();

Callers 5

digitsFunction · 0.70
mkPFunction · 0.70
mkSmallFunction · 0.70
mkBigFunction · 0.70
mkBigTypicalFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected