+ 4
Continue
What is the usage of continue?! Is it to skip for the next value!!
12 Respostas
+ 2
Jacob Burgess yes
+ 1
If you wany the loop to skip the rest of the current value commands you use continue
+ 1
Thank you 🌸
+ 1
Jacob Burgess thanks for the heads up. I had no idea of that issue.
+ 1
Continue
It's used for skipping the current iteration of a loop... And starts with the next iteration.
+ 1
When control encounters continue it reaches the start of the loop to continue the iteration.
+ 1
Yes, it is to skip the rest of current iteration and move to the next one in a loop. Some purists don't like goto statements and probably extend it to break and continue. I think, if not overused, there is nothing wrong with continue and break which can get rid of program inefficiency and some unnecessary clock cycles if they were not used.
0
Ur welcome
0
Jacob Burgess I don't understand why using continue and break statements would be bad practice?
0
Terminates the current iteration
0
Yes, it skips from your current position in the loop to the next. It's useful in many ways.
0
Yeh