Vidyalelo
C++ Programming · Q35

Exception Handling in C++

Programming · C++ Programming · question 35

Q35

What happens if an exception is thrown inside a destructor in C++?

A.
It leads to undefined behavior
Answer
B.
It is automatically caught and handled
C.
It causes the program to crash
D.
It is logged to a file

Answer: Option A

Solution

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