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

Function factorial

src/common/utils.ts:73–76  ·  view source on GitHub ↗

Helper to compute factorial for error messages

(n: number)

Source from the content-addressed store, hash-verified

71
72/** Helper to compute factorial for error messages */
73function factorial(n: number): number {
74 if (n <= 1) return 1;
75 return n * factorial(n - 1);
76}
77
78export function hidePrivateProperties(obj: any) {
79 for (const key in obj) {

Callers 1

permutationsFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected