change more for-each's into for's