What, if anything, prints when each of the following statements is performed? If nothing prints, then answer “nothing.” Assume x = 2 and y = 3.
```
a) cout << x;
b) cout << x + x;
c) cout << "x=";
d) cout << "x = " << x;
e) cout << x + y << " = " << y + x;
f) z = x + y;
g) cin >> x >> y;
h) // cout << "x + y = " << x + y;
i) cout << "\n";
```
a) 4
b) x=
c) x = 2
d) 5 = 5
e) nothing.
f) nothing.
g) nothing (because it is a comment). ANS: A newline is output which positions the cursor at the beginning of the next line on the screen.
You might also like to view...
Write a program that reads in exactly 10 integers and outputs the sum.
What will be an ideal response?
Explain how a package is named in Java.
What will be an ideal response?
What are the major considerations to take into account when planning for VoWiFi?
A. packet loss B. network protocol C. delay D. jitter
To make it easier to run a macro, you can assign the macro to ________
A) a menu B) a button C) the Quick Access toolbar D) the Ribbon