[prev] 26 [next]

Set ADT (cont)

Example set client: set of small odd numbers

Set s;  int i;
s = newSet();
for (i = 1; i < 26; i += 2)
    SetInsert(s,i);
showSet(s); putchar('\n');

Outputs:

{1,3,5,7,9,11,13,15,17,19,21,23,25}