Iterates with index over collection.