How horridly inefficient, he should have just flipped a Boolean on each iteration.
Horridly inefficient. Just unfold the loop.
Just output odd and even for each pass and increment by two. Need to make sure you have the right starting value, and check for off-by-one errors.
Horridly inefficient. Just unfold the loop.