Answer Posted / skybeaver
The "new" operator allocates a new instance of an object
from the heap, utilising the most appropriate constructor
for the arguments passed.
Like many operators in C++, the "new" operator for a
particular class can be overriden, although there is rarely
a need to do so. "operator new" is the mechanism for
overriding the default heap allocation logic. Ask your
interviewer to provide you with a concrete example of when
he or she has been required to do this.
| Is This Answer Correct ? | 14 Yes | 2 No |
Post New Answer View All Answers
How do you explain polymorphism?
What is debug class?what is trace class? What differences are between them? With examples.
What do you mean by Encapsulation?
write string class as your own class in java without using any built-in function
Why we use classes in oop?
Can we create object of abstract class?
What is persistence in oop?
What is multilevel inheritance?
why reinterpret cast is considered dangerous?
i=20;k=0;
for(j=1;k-i;k+=j<10?4:3)
{
cout< What are the features of oop? What is oops?what is its use in software engineering? Why do we use polymorphism? What are oops functions? How can you overcome the diamond problem in inheritance?