Jumping Out of Loops

While executing any loop, it becomes necessary to skip a part of the loop or to leave the loop as soon as certain condition becomes true, that is called jumping out of loop. C language allows jumping from one statement to another within a loop as well as jumping out of the loop.
There Are two keyword in C language to Jumping Out, or Breack Loop.

  • break statement
  • continue statement

break statement

When break statement is encountered inside a loop, the loop is immediately exited and the program continues with the statement immediately following the loop.

continue statement

It causes the control to go directly to the test-condition and then continue the loop process. On encountering continue, cursor leave the current cycle of loop, and starts with the next cycle.

Subscribe us on Youtube

Share This Page on

Ask Question