Documentation
    Preparing search index...

    Variable productConst

    product: (values: number[]) => number

    Product of all values in the array If the array is empty, it returns 1 (1 is identity element for multiplication)

    Type declaration

      • (values: number[]): number
      • Parameters

        • values: number[]

        Returns number

        product of all values

    import { product } from '@kitsuyui/mymath'
    product([1, 2, 3, 4]) // => 24