Convert for loops to fast enumeration