Start with a value at 0. Loop while value mod 6 is not equal to 0. Each time through the loop, add 1 to the value then print it. The loop must execute at least once.
int val = 0; do{ val++; cout << val << endl; }while(val % 6 != 0);
Content is available under GNU Free Documentation License 1.2.