add end postion to iterator print