Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialsathish
5,697 Pointscan any one help me on difference between "break" and "continue" and please explain the uses of "continue" keyword
an any one help me on difference between "break" and "continue" and please explain the uses of "continue" keyword thanks in advance
2 Answers
Steven Parker
231,269 PointsBoth of these words are used inside a loop. A "break" will cause the loop to immediately end, and the program flow jumps to the code after the loop. But a "continue" causes the loop to start the next iteration (ending the current one, but not the loop itself).
sathish
5,697 Pointsthank you very much sir