class COMBI_NR_STREAM
****
generate all combinations of {1..n} C(n,r) by lexical order. K.Kodama




Public


Readable Attributes
attr num:CARD;
attr pos:ARRAY{CARD};
**** 1<=pos[i]<=n-r+i
attr rank:CARD;

Writable Attributes
attr num:CARD;
attr pos:ARRAY{CARD};
**** 1<=pos[i]<=n-r+i
attr rank:CARD;

Features
create(n,r:CARD):SAME
get(out c:ARRAY{CARD}):BOOL
**** format: [0, combination of 1 to n ] For C(n,0). return |0| once.

The Sather Home Page