• Type Parameters

    • T

    Parameters

    • Rest ...inputs: ROArrayArray<T>

      arrays of numbers to calculate cartesian product over

    Returns ROArrayArray<T>

    the cartesian product (NxMx...) of a set of arrays

    This is implemented by calculating the cross of a single input against an intermediate result for each input to build up the final array of arrays.

    There are examples of doing this more succinctly using map & reduce online, but they are a bit more opaque to read.

Generated using TypeDoc