InterviewSolution
Saved Bookmarks
| 1. |
When is it advised to have user defined destructor?(a) When class contains some pointer to memory allocated in class(b) When a class contains static variables(c) When a class contains static functions(d) When a class is inheriting another class onlyThis question was addressed to me during an online exam.Origin of the question is Destructors topic in division Constructors and Destructors of Object Oriented Programming |
|
Answer» The correct answer is (a) When class contains some pointer to MEMORY allocated in class |
|