Question: Please use c++ for this problem. thank you In the following code, correct any errors that would prevent the program from compiling or running: include

Please use c++ for this problem. thank you

In the following code, correct any errors that would prevent the program from compiling or running:

include

main () { int num1, num2; bool found; cout << "Enter two integers: ; cin >> num1 >> num2; cout << endl; if(num1 >= num2) && num2 > 0 switch (num % num2) { case 1 found = (num / num2) >= 6; break; case 2: case 3 num1 = num2 / 2; brake; default: num2 = num1* num2; } else { found = (2 * num2 < num1); if found cin >> num2 num 1 = num2 - num1; temp = (num1 + num2) / 10; if num2 { num1 = num2; num2 = temp; } cout << num1 << " " << num2 << endl; }

a - What is the output if the input is 10 8?

b - What is the output if the input is 4 9?

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!