How to construct virtual constructor
Answer Posted / shakti singh khinchi
Virtual constructors are not used in any case in c++, bcz
the construction order in c++ should always remains from
base to derived , no one can changed their construction
order, so no need to declare constructor as virtual. But if
anyone wants to make it virtual then it is possible to make
a constructor virtual but it is against the OOPs.
| Is This Answer Correct ? | 12 Yes | 2 No |
Post New Answer View All Answers
What is the main function c++?
Describe new operator?
What are the comments in c++?
Can static member variables be private?
What is #include iostream in c++?
Which is the best c++ compiler?
What is the difference between reference and pointer?
What is the protected keyword used for?
What are the benefits of oop in c++?
What is the difference between interpreters and compilers?
Where Malloc(), Calloc(), and realloc() does get memory?
an operation between an integer and real always yeilds a) integer result b) real result c) float result
What are shallow and deep copy?
How can we access protected and private members of a class?
What is the difference between structures and unions?