What is the “continue” keyword and how does it work in Java?

A continue statement without a label will re-execute from the condition the innermost while or do loop, and from the update expression of the innermost for loop. It is often used to early-terminate a loop’s processing and thereby avoid deeply-nested if statements. In the following example continue will get the next line, without processing the following statement in the loop. With a label, continue will re-execute from the loop … Read more