node-worker-factorial
node-worker-factorial copied to clipboard
1n , what is means??
const calculateFactorial = numArray => numArray.reduce((acc, val) => acc * val, 1n); https://github.com/BuildingXwithJS/node-worker-factorial/blob/f4e5e8372f29f18b2445534938954a8d4a8c042b/factorial-worker.js#L6
@wwb568109135 this is BigInt notation, for more info see MDN: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/BigInt