Java #32: Continue Statement Example

//Programmer: Akinwale Owi
//Company: Dagba Computers
//Program Purpose: Continue statement example

package dagbacomputers;

* @author Akin

import java.util.Scanner;

public class DagbaComputers {

* @param args the command line arguments
public static void main(String[] args)
int decision, days;

Scanner readInput = new Scanner(;

//Asking user for input 3 times(3 days)
for (days = 0; days 10) continue;

System.out.println(“Drink more water”);

}//end of for statement

//Printed just to test when your loop is done
System.out.println(“Program Done”);

}//end of main

}//End of DagbaComputers Class

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s