1.

What operation can be performed by destructor?(a) Abort the program(b) Resource cleanup(c) Exit from the current block(d) Terminate the programI had been asked this question at a job interview.This question is from Exceptions and Efficiency topic in portion Derived Classes, Templates & Exception Handling in C++ of C++

Answer»

The correct choice is (b) RESOURCE cleanup

The explanation is: It will be used to free all the resources that are used by the BLOCK of CODE during EXECUTION.



Discussion

No Comment Found

Related InterviewSolutions