write a program to assign three numbers a,b and c. calculate the expression given below and display the value of p.
m=1/a + 1/b + 1/c
n=(a/a+b) + (b/b+c) + (a/c+a)
P=m + n
Take the value of a=3, b=4, c=5
Answers
Answered by
0
Answer:
I don't know javaaaaaaaaaaaaaaaaaaaaaassssssassssssssaaaaaaaaaaaaaaaa
Answered by
0
Answer:
import java.util.*;
class Third
{
public static void main()
{
System.out.print("enter three words");
Scanner sc = new Scanner(System.in);
int a = sc.nextInt();
int b = sc.nextInt();
int c = sc.nextInt();
int m = 1/a + 1/b + 1/c;
int n = (a/a+b) + (b/b+c) + (a/c+a);
int p = m+n;
System.out.println("\fif m is = "+m);
System.out.println("änd n is = "+n);
System.out.println("then p is = "+p);
}
}
Similar questions