Vidyalelo
C++ Programming · Q209

C++ miscellaneous

Programming · C++ Programming · question 209

Q209

What will be the output of the following C++ code? #include #include using namespace std; class A ; int main() char c; float x; if (typeid(c) != typeid(x)) cout << typeid(c).name() << endl; cout << typeid(A).name(); return 0;

A.
c
1A
Answer
B.
x
C.
Both c & x
D.
c

Answer: Option A

Solution

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