InterviewSolution
Saved Bookmarks
| 1. |
In C++, if new operator is used, when is the constructor called?(a) Before the allocation of memory(b) After the allocation of memory(c) Constructor is called to allocate memory(d) Depends on codeI had been asked this question by my school teacher while I was bunking the class.Asked question is from New Operator in portion Memory Allocation & Scope of Variable of Object Oriented Programming |
|
Answer» The correct choice is (b) After the allocation of memory |
|