Which of the following statement is NOT correct regarding Virtual function in C++?
Which of the following statement is NOT correct regarding Virtual function in C++?
I. It must be a member of some class.
II. It is accessed by using object points.
Show answerHide answer
Correct answer: (D) Neither I nor II
Explanation
Both statements are true: a virtual function must be a member of a class, and it is accessed through object pointers (base-class pointers) for run-time polymorphism. So neither is incorrect.