Java Utililty Methods Array Cross Product

List of utility methods to do Array Cross Product

Description

The list of methods to do Array Cross Product are organized into topic(s).

Method

Object[][]crossProduct(Object[] firstArray, Object[]... otherArrays)
Cross product many arrays
if (otherArrays == null || otherArrays.length == 0) {
    Object[][] result = new Object[firstArray.length][1];
    for (int i = 0; i < firstArray.length; ++i) {
        result[i][0] = firstArray[i];
    return result;
Object[][] restArray = new Object[otherArrays.length - 1][];
...