Comments on Loopy C Puzzle
Ryan said:
int i;
for (i = 0; -i < 6; i--)
printf(".");
Sean said:
Changing the loop condition to i ^= 6;
is another solution.
Ryan said:
Ah-ha, a tricky one:
int i;
for (i = 0; i ^= 6; i--)
printf(".");
Ryan said:
Ah, Sean beat me to it. :(
Martin DeMello said:
for (i = 0; i + 6; i--)
will stop when i + 6 = 0.
Ryan said: