Question: Consider the following statement: my _ obj - > myfun ( ) ; Why is it not possible from this statement alone to determine which

Consider the following statement:
my_obj->myfun();
Why is it not possible from this statement alone to determine which member function myfun()will be executed?
Question 4 options:
Because the variable my_obj may also be stored in an array or a vector
Because the function myfun()does not have parameters
Because the variable my_obj is a pointer
Because the object pointed to by my_obj might be a derived object

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!