I have a php array $numbers = array(1,2,3,4,5,6,7,8,9)
$numbers = array(1,2,3,4,5,6,7,8,9)
if I am looping over it using a foreach foreach($numbers as $number)
foreach($numbers as $number)
and hav
Break; will stop the loop and make compiler out side the loop. while continue; will just skip current one and go to next cycle. like:
$i = 0; while ($i++) { if ($i == 3) { continue; } if ($i == 5) { break; } echo $i . "\n"; }
Output:
1 2 4 6 <- this won't happen