64 604
Assignments Done
99,1%
Successfully Done
In September 2018

Answer to Question #3558 in Java | JSP | JSF for Y mukundareddy

Question #3558
(1) Write a program to perform all arithmetic operators on the following variables a=5, b=10?
Expert's answer
public class Arifmetic {
public static void main(String[] args){
& int a = 5;
& int b = 10;
& int plus = a+b;
& int minus = a-b;
& int mult = a*b;
& double div = (double) a/b;
& System.out.println(a+" + "+b+" = "+plus);
& System.out.println(a+" - "+b+" = "+minus);
& System.out.println(a+" * "+b+" = "+mult);
& System.out.println(a+" / "+b+" = "+div);
}
}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be first!

Leave a comment

Ask Your question

Submit
Privacy policy Terms and Conditions