May 22, 2014 at 6:08pm
Because you're forever adding entries to the vector.
When you get to any odd number, you add it to the end of the vector, thereby increasing the size of the vector.
edit: Struck out "the end of".
Last edited on May 22, 2014 at 6:27pm
May 22, 2014 at 6:31pm
Oh thank you all, so I would need to do iter += 2;
to fix it. Thank you guys