DEV Community

hema latha
hema latha

Posted on

if else condition program_basic

package day1;

public class demo2 {
public static void main(String[] args) {
int number = 13;
//Check if the number is divisible by 2 or not
if(number%2==0)
{
System.out.println("even number");

}
else
{

System.out.println("odd number");

}

}

Top comments (0)