boutique replica bags up ideas

the best replique rolex and prices here.

julia highlight 99j hair color 10a quality straight human hair lace front wigs 8 - 24 inches pre plucked hairline 13x4 inches lace front brazilian wig onlinefor sale

JavaScript break and continue Statements Example

Updated on     Kisan Patel

In javascript, the break statement is used to break the loop completely in middle.

The following script shows the use of break.

for (i = 10; i >= 0; i--) {
   if (i == 5) {
      break;
   }
}
document.write("My Lucky number is" + i);

See the Pen xGeXZZ by Kisan (@pka246) on CodePen.

The continue statement is used to skip the current iteration and continue with the next iteration of the loop.

for (i = 10; i >= 0; i--) {
   if (i == 5) {
      x = i;
      continue;
   }
   document.write(i);
   document.write("<br/>");
}
document.write("The number " + x + " is missing in above list");

See the Pen mJgBVB by Kisan (@pka246) on CodePen.


JavaScript

Leave a Reply