Assignment 1(b) Calculator

Assignment 1(b) Calculator
Write a new C++ program that allows the user to perform simple calculations using to the following
1. The program writes a greeting on the screen.
2. The program writes a short message (about one line) describing how to use it.
3. The program lets the user enter a number.
4. The program lets the user enter an operator.
5. The program lets the user enter a number.
6. If the operator equals “+”, then the program calculates and displays the sum of the two
numbers entered by the user.
7. The program can also compute and display the result for “-“, “*”, “/”
8. If the operator is not +, -, *, or /, then the program terminates.
9. If the program does not terminate, then it repeats these operations from step 2.
The output of the program might look like this:

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.