C5i interview question

Explain for loop and related coding question