Question: please write in java with explanations so i can understand, thank you. Program Requirements The program shall have a separate method for each arithmetic operation

please write in java with explanations so i can understand, thank you.

please write in java with explanations so i can understand, thank you.Program Requirements The program shall have a separate method for each arithmeticoperation (including power, "A) that will return the result le: add(), subtract(),

Program Requirements The program shall have a separate method for each arithmetic operation (including power, "A) that will return the result le: add(), subtract(), etc... Note: For the power function, you CANNOT use Math.pow(), assume you will never get power = le: "1 + 2 = 3" The program shall have a method called isValidOperator that takes the input for the operator and returns a boolean value of whether or not it is a valid operator If the operator was not valid, display an error message and let the program exit Notes/Tips . What data type should we be expecting from the user for the operands? THINK: If the user wanted to do 2/3, what data types would we need to provide the correct/expected result? The order in which you accept input does not matter - it is up to your desired design Remember to close the scanner at the end of the program (I will take off points if you do not close the scanner) Sample Output NOTE: Print lines with "**" at the start do not need to be in your program. They are just auxiliary print statements in the example Welcome to my Expression Evaluator! Enter an operand: 2.3 Enter an operand: 2.5 Enter an operator (+,-*,/,^): Checking if 't' is a valid operator... ** '+' is a valid operator! 2.3 + 2.5 = 4.8 Ending program... Welcome to my Expression Evaluator! Enter an operand: 2.6 Enter an operand: 9.7 Enter an operator (+,-*,/,^): nuts ** Checking if 'nuts' is a valid operator... ** 'nuts' is NOT a valid operator! The operator you entered was not a proper operator Ending program

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!