0
why in this code the output increment 2 number inside the code while the i == 0đ€đ€đ€
<?php for ($i=0; $i<10; i++) { if ($i%2==0) { continue; } echo $i . ' '; } ?>
1 Answer
+ 3
continue; moves the loop back to the top (or the next itteration).
So when the continue statement is reached, the for loop is considered done and i is incremented from the i++.