While vs For-loop : <p>Are these basically the same?</p>

<p>1) While</p>

<pre><code>int i = 0, j = 0;

while (i &lt; 10) {
    while (j &lt; 10) {
    } j++;
} i++;
</code></pre>

<p>2) For</p>

<pre><code>for (int i = 0; i &lt; 10; i++) {
    for (int j = 0; j &lt; 10; j++) {
    }
}
</code></pre>

<p>Still kind of new to programming and I just wanted to know. Which one would be more efficient if they are the same?</p>
