Question: Write a Java program that reads two numbers from the console. Based on the example in the textbook, write five methods ( min, max, sum,
Write a Java program that reads two numbers from the console. Based on the example in the textbook, write five methods (min, max, sum, difference, and product) to calculate and return the appropriate results. For the difference method, use the absolute value method and the round method from the Math class to refine your results to the nearest whole positive integer

PreLab06 Protected View Saved to this PC Review View Help PDF Pro 10 Tell me what y CSC108 PreL ab06 Write a Java program that reads two numbers from the console. Based on the example in the textbook, write five methods (min, max, sum, difference, and product) to calculate and return the appropriate results. For the difference method, use the absolute value method and the round method from the Math class to refine your results to the nearest whole positive integer. Here are two sample runs: Enter two numbers: 2 3 The minimum of 2.0 and 3.0 is 2.0 The maximum of 2.0 and 3.0 is 3.0 The sum of 2.0 and 3.0 is 5.0 The difference between 2.0 and 3.0, rounded to the nearest whole integer, is 1 The product of 2.0 and 3.0 is 6.0 Enter two numbers: 11.75 1.5 The minimum of 11.75 and 1.5 is 1.5 The maximum of 11.75 and 1.5 is 11.75 The sum of 11.75 and 1.5 is 13.25 The difference between 11.75 and 1.5, rounded to the nearest whole integer, is 10 The product of 11.75 and 1.5 17.625 Please rename your project folder to "Your Name PreLab06" and send me your zipped project file as an attachment in a Blackboard message
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
