Suppose that num is an int variable. Consider the following C++ code:
cin >> num;
if (num >= 0)
switch (num)
{
case 0:
num = static_cast
break;
case 2:
num = ++num;
break;
case 4:
num = num – 4;
break;
case 5:
num = num * 4;
case 6:
num = num / 6;
break;
case 10:
num--;
break;
default:
num = -20;
}
else
num = num + 10;
a. What is the output if the input is 5?
b. What is the output if the input is 26?
c. What is the output if the input is 2?
d. What is the output if the input is -5?
We need at least 10 more requests to produce the solution.
0 / 10 have requested this problem solution
The more requests, the faster the answer.