Function factorial

  • This method calculates the factorial of a non-negative integer n. ie the number of permutation of n elements.

    Parameters

    • n: number

      Number of elements.

    Returns f64

    The factorial of n.

    Remarks

    • The function uses a loop to multiply all the integers from 2 to n inclusive to obtain the factorial.

Generated using TypeDoc