Write a program in java to calculate big value of 2 numbers
import java.util.*;
class big
{
public static void main(String obj [ ])
{
int a, b;
Scanner.sc=new scanner (system.in);
System.out.println (“Enter the value of a & b”);
a=sc nextInt ();
b=sc nextInt ();
if(a>b)
system.out.println(“a is big”);
if(b>a)
system.out.println(“b is big”)
}
}
class big
{
public static void main(String obj [ ])
{
int a, b;
Scanner.sc=new scanner (system.in);
System.out.println (“Enter the value of a & b”);
a=sc nextInt ();
b=sc nextInt ();
if(a>b)
system.out.println(“a is big”);
if(b>a)
system.out.println(“b is big”)
}
}
Subscribe to:
Post Comments
(
Atom
)
No comments :
Post a Comment