CJCoding With Joseph
15free / daySign inCreate account
Back to Multiple Choice Quiz

Select topics to narrow your question pool, then enable Random to jump to a random question matching your filters.

Topics

Reference vs Copy

C++ quiz · Question 2
mediumVariables

What is the output of this code?

Code

1#include <iostream>
2using namespace std;
3 
4int main() {
5 int a = 5;
6 int &b = a;
7 b = 10;
8 cout << a << endl;
9 return 0;
10}