Iterate two things together at once:
iter1.zip(iter2).map(|(i1,i2)|…)
for (i1,i2) in iter1.zip(iter2) {…}
To iterate more you can nest zip():
for ((i1,i2),i3) in iter1.zip(iter2).zip(iter3) {}
or better, use Itertools::multizip.
iter.zip example: https://is.gd/5Xq53J
@rust Actually I needed it yesterday. I'm going to take a look at iterators soon. I can see that they are interesting.