Answers to Self-Review Exercises (Sections G.6G.13)

G.3

a) abstract.

b) concrete.

c) Polymorphism.

d) abstract.

e) downcasting.

G.4

a) False. An abstract class can include methods with implementations and abstract methods.

b) False. Trying to invoke a subclass-only method with a superclass variable is not allowed.

c) False. Only a concrete subclass must implement the method.

d) True.

Get Android™ How to Program, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.