What does this code in the loop do?