public class ifElse
{
public static void main (String[] args)
{
int a = 20;
if (a %2 == 0)
{
System.out.println(" Number is even");
}
else
{
System.out.println("Number is odd");
}
}
}
{
public static void main (String[] args)
{
int a = 20;
if (a %2 == 0)
{
System.out.println(" Number is even");
}
else
{
System.out.println("Number is odd");
}
}
}
No comments:
Post a Comment