• + 0 comments

    If N is passed it a Even Number . Then check other condition of Range * then check N < 5 check the Event number from 2 to 5 between and Print " Not Weird" *Else If If the N is greater then 5 and less or equal to 20 then N<= 20 condtion check it. * If the N is greate then 20 the Esle condition is print If the Number is not pass the N % 2 == 0 that condition then print the Outer Else statement.

    if(N % 2 == 0 ){ if(N<5){

                System.out.println("Not Weird");
            }else if (N<=20){
                System.out.println("Weird");
            }else{
                System.out.println("Not Weird");
            }
        }else {
            System.out.println("Weird");
        }
    

    scanner.close(); }