1.

What will be the correct syntax for running two variable for loop simultaneously?

A. <pre class="prettyprint lang-c">for (k = 0, L = 0; k &lt; num, L &lt; num; k++, L += 5)<br></pre>
B. <pre class="prettyprint lang-c">for (k = 0; k &lt; num; k++){}<br> for (L = 0; L &lt; num; L += 5){}<br></pre>
C. <pre class="prettyprint lang-c">for (k = 0; k &lt; num; k++)<br> for (L = 0; L &lt; num; L += 5)<br></pre>
D. All of above
E. None of these
Answer» B. <pre class="prettyprint lang-c">for (k = 0; k &lt; num; k++){}<br> for (L = 0; L &lt; num; L += 5){}<br></pre>


Discussion

No Comment Found

Related MCQs