Question: Write a console program to: 1. Prompt the user to enter two decimal numbers followed by an arithmetic operator ( +, -, / or *).

Write a console program to: 1. Prompt the user to enter two decimal numbers followed by an arithmetic operator ( +, -, / or *).

2. Call a function to do the specified arithmetic operation and return the result

3. Display the arithmetic expression followed by an equal sign followed by the result as a floating point number, with 2 decimal places and then with 3 decimal places on separate lines. Example: 3.00 + 2.00 = 5.00

4. Prompt the user to see if they want to do more calculations. Allow the user to do more calculations until they enter either an Nor an n for no.

5. Use a for-loop to display 5 random numbers. Display a heading above the random numbers.

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!