You're right, it should be specialsCounter = i. This worked as is because the next time through the loop the first branch of the if would catch it and move specialsCounter to where it needs to be.