Answer Posted / priyanka kokil
I want to modify the above answer. A constructor cannot be
virtual because at the time when the constructor is invoked
the virtual table would not be available in the memory.
Hence we cannot have a virtual constructor. But we can have
virtual destructor which is defined in Answer #2
| Is This Answer Correct ? | 5 Yes | 0 No |
Post New Answer View All Answers
What's the order in which the objects in an array are destructed?
What is input operator in c++?
what is the difference between linear list linked representaion and linked representation? what is the purpose of representing the linear list in linked represention ? is it not avoiding rules of linear represention?
Can we get the value of ios format flags?
What will the line of code below print out and why?
What are friend classes?
Explain what data encapsulation is in c++?
What is fixed in c++?
What is the size of integer variable?
What is array give example?
What do you mean by static variables?
What does getch() do according to the ANSI C++ standard a) Reads in a character b) Checks the keyboard buffer c) Nothing in particular (Its not defined there)
What causes a runtime error c++?
How much is c++ certification?
How can you quickly find the number of elements stored in a static array?