Make sure eachWithIndex passes index *then* increments

Switches pre-increment to post-increment in eachWithIndex.