The Continue Keyword in Java

The proceed with decisive word can be utilized as a part of any of the loop control structures. It causes the loop to quickly bounce to the following emphasis of the loop.

  • In a for circle, the continue keyword reasons stream of control to quickly bounce to the overhaul articulation.
  • In a while or do/while loop, stream of control instantly hops to the Boolean interpretation.

The syntax of using this keyword is as follows:


Sample Implementation:

public class myTest {

public static void main(String args[]) {

int [] mynumbers = {0, 5, 10, 15, 20};

for(int i : mynumbers ) {

if( i == 15 ) {



System.out.print( i );





The expected output of the code is:


For any query or issue, feel free to discuss on