1.

Which among the following is true?(a) Abstract methods can be static(b) Abstract methods can be defined in derived class(c) Abstract methods must not be static(d) Abstract methods can be made static in derived classI had been asked this question by my school teacher while I was bunking the class.The doubt is from Abstract Function topic in portion Member Functions & its Types of Object Oriented Programming

Answer»

The correct option is (c) Abstract METHODS must not be static

Explanation: The abstract methods can never be made static. Even if it is in DERIVED class, it can’t be made static. If this happens, then all the subsequent SUB classes will have a common definition of abstract FUNCTION which is not desirable.



Discussion

No Comment Found

Related InterviewSolutions