EnumerableUtility.CrossProduct<T> method (1 of 2)

Returns the Cartesian cross-product of a sequence of sequences.

public static IEnumerable<IEnumerable<T>> CrossProduct<T>(this IEnumerable<IEnumerable<T>> sources)
parameter description
sources The sources.

Return Value

A new sequence of sequences, where the first item in each sequence is from the first input sequence, the second item is from the second input sequence, and so on.

See Also


EnumerableUtility.CrossProduct<TSequence,TItem> method (2 of 2)

Returns the Cartesian cross-product of a sequence of sequences.

public static IEnumerable<IEnumerable<TItem>> CrossProduct<TSequence, TItem>(
    this IEnumerable<TSequence> sources)
    where TSequence : IEnumerable<TItem>
parameter description
sources The sources.

Return Value

The cross product.

See Also