It works without the additional braces. Consider this:<p><pre><code>    for (i=0;i&lt;imax;i++)
        printf(&quot;%d\n&quot;, i);
</code></pre>
You can omit the braces if the body of the loop is a single block, just like an if statement. You can also do this:<p><pre><code>    if (a == b)
        if (b == c)
        {
            do_thing();
        }
</code></pre>
Same deal with the for loop. The nested loop is a single block.