Vidyalelo
C++ Programming · Q107

Variables and Data Types in C++

Programming · C++ Programming · question 107

Q107

What will be the output of the following C++ code? #include using namespace std; int main() void a = 10, b = 10; int c; c = a + b; cout << c; return 0;

A.
20
B.
compile time error
Answer
C.
runtime error
D.
40

Answer: Option B

Solution

Answer: Option B
No explanation is given for this question Let's Discuss on Board