What will the following code display?
```
#include
using namespace std;
void doSomething(int);
int main()
{
int x = 2;
cout << x << endl;
doSomething(x);
cout << x << endl;
return 0;
}
void doSomething(int num)
{
num = 0;
cout << num << endl;
}
```
a. 2
0
2
b. 2
2
2
c. 0
0
0
d. 2
0
0
a. 2
0
2
You might also like to view...
The overall success of the personnel security function depends on the organization's ability to ____.
A. ensure its long-term effectiveness B. ensure its short-term effectiveness C. hire quality employees D. pay its employees well
The mathematical formula for calculating a periodic payment on a loan is rather complex, so Visual Basic provides a method that performs the calculation for you.
Answer the following statement true (T) or false (F)
Which of the following is the path to the Ruler check box?
A. (HOME tab | Rulers group) B. (DESIGN tab | Check Box group) C. (VIEW tab | Show group) D. (VIEW tab | Rulers group)
Prompt the user to enter the first integer.
What will be an ideal response?