Legend

Class
Struct
Enum
Interface
Delegate
Constructor
Method
Property
Event
Field

Static method: IEnumerable<int[]> Combinations(int, int, int, bool)

Declaration

public static IEnumerable<int[]> Combinations(
    int minValue,
    int maxValue,
    int numDigits,
    bool allowDuplicates = false
)

Summary

Generates all combinations of numDigits digits, each between minValue and maxValue.

Parameters

intminValue Minimum value to use.
intmaxValue Maximum value to use.
intnumDigits Number of digits in each combination.
boolallowDuplicates If true, duplicated digits are allowed.