tgen
Loading...
Searching...
No Matches
Pairs

Generation of pairs of integral types. More...

Classes

struct  tgen::pair< T >
 Pair generator. More...
struct  tgen::pair< T >::value
 Pair value. More...

Detailed Description

Generation of pairs of integral types.

Examples

Prints 10 different pairs of values from 1 to n, with first <= second.

std::cout <<
tgen::pair<int>(1, n).leq().distinct().gen_list(10).separator('\n') << std::endl;
auto distinct(Args &&...args) const
Creates distinct generator for current generator.
Definition tgen.h:360
Pair generator.
Definition tgen.h:3471
pair & leq()
Restricts generator s.t. first is less than or equal to second.
Definition tgen.h:3516