Suppose this is embedded in an otherwise correct and complete program. Which version of f() will be called?
Suppose class D is derived from class B, and class B has a public
member function whose declaration is void f();. Suppose class D has its
version of the function, void f(). Here is a pointer definition and an access to a
member function..
```
B* bPtr = new D;
BPtr->f();
```
a) D::f()
b) B::f()
c) This is illegal. You can’t assign a D object to a variable of type pointer to B.
b) B::f()
Computer Science & Information Technology
You might also like to view...
The space between a node’s contents and its top, right, bottom and left edges is known as the ________, which separates the contents from the node’s edges.
a. margin b. spacing. c. padding. d. None of the above.
Computer Science & Information Technology
The