If a base class has a virtual function named print, and a pointer variable of that class is pointing to a derived object, then the code ptr->print ) ; calls
A) the base class print function
B) the derived print function
C) both the derived and base print functions
D) it causes a run-time error
Correct Answer:
Verified
Q36: If a base class has a public
Q37: Using inheritance allows us to
A) eliminate duplicate
Q38: When deriving a class, you should
A) list
Q39: Another name for the base class is
A)
Q40: If the member variables in a base
Q42: If you have a copy constructor in
Q43: If a base class has a non-virtual
Q44: If a derived class Class2) has redefined
Q45: Given the following classes and code, what
Q46: Given the following classes and code, what
Unlock this Answer For Free Now!
View this answer and more for free by performing one of the following actions
Scan the QR code to install the App and get 2 free unlocks
Unlock quizzes for free by uploading documents