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 is the difference between map and hashmap in c++?
Explain queue. How it can be implemented?
List the types of polymorphism in c++?
How can I disable the "echo" feature?
Can you explicitly call a destructor on a local variable?
What are features of c++?
What is a loop? What are different types of loops in c++?
Can we inherit constructor in c++?
What is the difference between the parameter to a template and the parameter to a function?
What does it mean to declare a member function as static?
Why cout is used in c++?
What is a constant reference?
What is the best c++ compiler?
What is buffer and example?
What is insertion sorting?