+ 1

can you help me solve c++ question

Q1. Write a program so that it repeatedly asks for an arithmetic operator (+, -, *, /) and two operands from a user and performs the operation on those two operands depending upon the operator entered by user the program will terminate if the user entered the letter 'n'.

3rd Feb 2021, 6:57 AM
Faisal Awad
Faisal Awad - avatar
3 Answers
+ 6
I'm not gay myself.
3rd Feb 2021, 7:20 AM
Sonic
Sonic - avatar
+ 1
Do you mean a calculator? If so, its very simple. Input 3 different variables, then use if statement or switch(for the operator) and output their result.
3rd Feb 2021, 9:47 AM
Maher Al Dayekh
Maher Al Dayekh - avatar
- 1
Q1. Write a program so that it repeatedly asks for an arithmetic operator (+, -, *, /) and two operands from a user and performs the operation on those two operands depending upon the operator entered by user the program will terminate if the user entered the letter 'n'.
3rd Feb 2021, 7:32 AM
Faisal Awad
Faisal Awad - avatar