Small change to for loops, fixing eclipse warnings.