Question: 2. Write a Java program that create two variables of type integer and initially assign their values to 125, 24 and then print the result

2. Write a Java program that create two variables of type integer and initially assign their values to 125, 24 and then print the result of the following arithmetic operations in separate lines: a. Addition b. Subtraction c. Multiplication d. Division e. Reminder Finally, ask the user to enter two numbers and then print the result of the above arithmetic operations of those numbers in separate lines too. Solve it using constructors and set and get method
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
