1.

Which of these keywords can be used to prevent inheritance of a class?(a) super(b) constant(c) class(d) final

Answer» The correct choice is (d) final

For explanation I would say: Declaring a class final implicitly declared all of its methods final, and makes the class inheritable.


Discussion

No Comment Found

Related InterviewSolutions