+ 2

How to print the odd numbers...by using breaking function

https://code.sololearn.com/cLCnVy42hxVu/?ref=app Here i can only get the output as 1

28th May 2019, 9:44 AM
Y AD Ù
Y AD Ù - avatar
1 Resposta
+ 12
Replace 'break' with 'continue' ------- The 'break' keyword terminates the current execution of loop. While the 'continue' keyword passes the control flow to the next iteration ( when 2 is encountered, it jumps any statement following it ).
28th May 2019, 9:54 AM
Nikhil
Nikhil - avatar