Back To Java Flow of Control Index
//program to demonstrate if-else statement example 6, check whether a is less than or equal to 10 or greater than 10 public class ifelseexample6 { public static void main(String[] args) { int a; a=9; if(a<10) { System.out.println("a is less than 10"); } else { System.out.println("a is either greater than or equal to 10"); } } }