WAP to check maximum of three numbers.Also write an algorithm
Answers
Answered by
0
Answer:
import java.util.*;
class max
{
public static void main (string args[])
{
Scanner in =new Scanner(System.in);
int a,b,c,x,y;
System.out.println("Enter three numbers");
a=in.nextInt();
b=in.nextInt();
c=in.nextInt();
x=Math.max(a,b);
y=Math.max(c,x);
System.out.println("Greatest number="+y);
}
}
.
.
.
*Hope it will help you*
Similar questions
Social Sciences,
4 months ago
Science,
4 months ago
Math,
8 months ago
Biology,
11 months ago
Chemistry,
11 months ago