Computer Science, asked by mkhetan122, 1 year ago

1. switch case construct into if-else-if :
switch(n)
case 1:
s=a+b;
System.out.println("Sum="+s);
break;
case 2:
d=a-b;
System.out.println("Difference="+d):
break:
case 3:
p=a*b;
System.out.println("Product="+p);
break;
default:
System.out.println("Wrong Choice!");​

Answers

Answered by fbbackupbretta
9

Answer:

Here is your answer

Explanation:

After converting

If(n==1)

{

S=a+b;

System.out.println("sum="+s) ;

}

Else if(n==2)

}

D=a-b

System.out.println("Diffrences="+d);

}

Else if(n==3)

{

P=a*b;

System.out.println("product"="+p);

}

Else

System.out.println("wrong choice");

Plz mark as brainliest

Similar questions