write a program to input appropriate values and print the result
(in Java)
plz help
Answers
Answered by
1
import Java. so. *;
class p
{
public static void main(String arts[])throws exception
{
DataInputStream in=new DataInputStream(System.in);
int a, b, c;
Sopln("enter the value of a and b");
a=Ip;
b=Ip
c=math.sqrt(a*a)+math. sqrt(b*b);
Sopln("the answer is "±c);
}
}
sopln--System. out. print
Ip=Integer.parseInt(in.readLine());
Hope it helps (。’▽’。)♡
class p
{
public static void main(String arts[])throws exception
{
DataInputStream in=new DataInputStream(System.in);
int a, b, c;
Sopln("enter the value of a and b");
a=Ip;
b=Ip
c=math.sqrt(a*a)+math. sqrt(b*b);
Sopln("the answer is "±c);
}
}
sopln--System. out. print
Ip=Integer.parseInt(in.readLine());
Hope it helps (。’▽’。)♡
pragyapathak12:
thx
Similar questions