Rearrange loop and comment