Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Design a calculator that performs four operations: addition, multiplication, div

ID: 3678767 • Letter: D

Question

Design a calculator that performs four operations: addition, multiplication, division and subtraction with 2 integer type numbers.

a) Ask user what type of operation to perform (+, -, * or /) a. If the user inputs ‘none’ then the program terminates. Otherwise it will keep continuing the calculation. (hint: use while) b) Ask user to provide 2 integer number inputs

c) Perform operation (whatever operation they mentioned in a)

d) Print result

e) In division operation, perform a check if the denominator is a 0. If it is 0, then print a message that – denominator cannot be 0 while performing a division operation

Explanation / Answer

# include using namespace std; int main() { char o; int num1,num2; cout > o; cout > num1 >> num2; switch(o) { case '+': cout
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote