Self-Review Exercises (Sections G.1G.5)

G.1 Fill in the blanks in each of the following statements:

a) _____________ is a form of software reusability in which new classes acquire the members of existing classes and embellish those classes with new capabilities.

b) A superclass’s _____________ members can be accessed in the superclass declaration and in subclass declarations.

c) In a(n) _____________ relationship, an object of a subclass can also be treated as an object of its superclass.

d) In a(n) _____________ relationship, a class object has references to objects of other classes as members.

e) In single inheritance, a class exists in a(n) _____________ relationship with its subclasses.

f) A superclass’s _____________ members are accessible ...

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.