Fixed for loop bounds