0
Please someone explain me break and continue in loops in easy words. A bit confused
Confused
6 odpowiedzi
0
break keyword will break all loops and will came out from loops and continue keyword use to jump certain loop and continue others, in break it will terminate all further loops.
0
I'm understanding it a little, I have a request that can u please type down a code to make it more clear
0
I've completely understood break, just explain continue, thankful for your help :)
0
https://code.sololearn.com/ccW8zlbk2X0Y/?ref=app
here I wrote simple program to print sum of even numbers.
0
To put it simply, if a break condition is met, the loop will terminate and the next line after the loop will execute. If a continue condition is met, no further statements in the loop will execute, the counter will increment and the loop will continue.