I have a requirement where i need to increment the FOR loop again even if the condition is already met
for ($i = 0; $i <=100; $i++) { statements ... if (defined $v) && ($i == 100) { $i = 2* $i } }
In the above code, i have defined a value $v and some statements related to $v to be executed only when $i reaches 100. I need to set $i as 200, if $v is defined. My code reaches the condition, however it is not incrementing . Is there a way to make it work
In reply to Incrementing the loop again. by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |