Question: Create an IPO chart, flowchart, pseudocode algorithm and desk check for a simple calculator program. This program repeatedly asks the user to select between options

Create an IPO chart, flowchart, pseudocode algorithm and desk check for a simple calculator program. This program repeatedly asks the user to select between options to add, subtract, multiply, divide or exit, then prompts for two numbers, carries out and displays the result of the operation, and then presents the user with the options again until the user chooses to exit. The program should include appropriate error checking to prevent the program from dividing by zero.

SAMPLE PROGRAM EXECUTION (user input is shown in blue for reference)

Select 1 to add, 2 to subtract, 3 to multiply, 4 to divide or any other number to exit: 1

Enter two numbers: 30 45

30 + 45 = 75

Select 1 to add, 2 to subtract, 3 to multiply, 4 to divide or any other number to exit: 4

Enter two numbers: 120 0

Error: Cannot divide by zero

Select 1 to add, 2 to subtract, 3 to multiply, 4 to divide or any other number to exit: 4

Enter two numbers: 120 10

120 / 10 = 12

Select 1 to add, 2 to subtract, 3 to multiply, 4 to divide or any other number to exit: 3

Enter two numbers: 6 12

6 x 12 = 72

Select 1 to add, 2 to subtract, 3 to multiply, 4 to divide or any other number to exit: 0

***END OF 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!