What is dynamic method dispatch, and why is it useful?
Inheritance and Polymorphism
Original Khojo Papers practice question — not from a past board paper.
An abstract class is one that cannot be instantiated and may contain both abstract methods, which have no body, and concrete methods with implementations. An interface traditionally contains only abstract methods and constants and defines a contract; a class may extend only one class but implement any number of interfaces.
No citable source has been recorded for this record. Treat it as practice material, not as fact.
Interfaces are how Java achieves the effect of multiple inheritance.
From the same topic and chapter, at a similar level.
What is dynamic method dispatch, and why is it useful?
Inheritance and Polymorphism
Why does Java not allow a class to extend more than one class?
Inheritance and Polymorphism
What does the super keyword do in Java?
Inheritance and Polymorphism
Distinguish between method overloading and method overriding.
Inheritance and Polymorphism
A class B extends class A, and both define a method show(). If A a = new B(); a.show(); is executed, which version runs and why?
Inheritance and Polymorphism
State and verify the absorption law X + X·Y = X using a truth table.
Boolean Algebra