1.

Which among the following can’t be used for polymorphism?(a) Static member functions(b) Member functions overloading(c) Predefined operator overloading(d) Constructor overloadingI got this question during an online exam.This interesting question is from Polymorphism topic in section OOPs Concept & Features of Object Oriented Programming

Answer»

The correct choice is (a) STATIC member FUNCTIONS

To EXPLAIN I would say: Static member functions are not property of any object. Hence it can’t be CONSIDERED for overloading/overriding. For polymorphism, function must be property of object, not only of class.



Discussion

No Comment Found

Related InterviewSolutions