Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a calculator that will give the user this menu options: 1)Add 2)Subtract 3)Multiply 4)Divide 5)Exit . Your program should continue asking until the user

Write a calculator that will give the user this menu options:

1)Add

2)Subtract

3)Multiply

4)Divide

5)Exit .

Your program should continue asking until the user chooses 5. If user chooses to exit give a goodbye message. After the user selections options 1 - 4, prompt the user for two numbers. Perform the requested mathematical operation on those two numbers. Round the result to 1 decimal place. Please answer in python and make it simple. Please implement proper indentation, not just a paragraph of code. Thanks.

Example 1:

Let's calculate!

1) Add

2) Subtract

3) Multiply

4) Divide

5) Exit

Please select one of options above: 4

Enter the first number: 2.81

Enter the second number: 1.111

Answer: 3.1

1) Add

2) Subtract

3) Multiply

4) Divide

5) Exit

Please select one of options above: 5

Have a good day!

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

T Sql Window Functions For Data Analysis And Beyond

Authors: Itzik Ben Gan

2nd Edition

0135861446, 978-0135861448

More Books

Students also viewed these Databases questions

Question

Trace the history of organized labor in the United States.

Answered: 1 week ago