Question: not sure how to modify my old code to make the while() loop terminate the program. please help and zoom in if needed. In Lab

not sure how to modify my old code to make the while() loop terminate the program. please help and zoom in if needed.

not sure how to modify my old code to make the while()

loop terminate the program. please help and zoom in if needed. In

In Lab 25. you were required to write a program that computed the result of a simple mathematical expression consisting of a floating point operand, an operator, and another floating point operand. This assignment requires you to modify that program so that it will continue to repeat until both operands contain a zero. For example, 0 + o should terminate your program. When the input is as shown in Figure 1. your program should produce the output as shown in Figure 2. Figure 1: (sample input) 3.27 / 9 7 9.95 -5 = -5 -5 - 5 Figure 2: (sample output) 3.27 / 9 = 0.363333 4 x 8.1 = 32.4 7 x 9.95 = 69.65 -5 + 5 = -10 -5 - -5 = 286488 1697136 5 #include 6 7 using namespace std; 8 int main() 10 1/define variables double numi, num2; char symbol; 12 13 cin numi symbol >> num2; 15 16 18 Switch (symbol) 19 20 cout

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!