plz solve this ptogram only with if statement.....write a java program to input two numbers and find the square of the greatest number.. plzzzzzzz solve ASAP.....plzzzzzzzz
Answers
Answered by
1
Answer:
Explanation:
import java.util.*
public static void main(String args{[])
{
Scanner sc;
int a,b,c;
a=sc.nextInt(System.in);
b=sc.nextInt(System.in);
if(a>b)
c=a*a;
else
c=b*b;
System.out.println("square of largest number is"+c);
}
Similar questions
Biology,
4 months ago
Math,
4 months ago
Math,
9 months ago
Math,
9 months ago
Social Sciences,
1 year ago