Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

G. Object-Oriented Programming: Inherita... > Self-Review Exercises (Sections G.6–...

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

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

a. If a class contains at least one abstract method, it’s a(n) __________ class.

b. Classes from which objects can be instantiated are called __________ classes.

c. __________ involves using a superclass variable to invoke methods on superclass and subclass objects, enabling you to “program in the general.”

d. Methods that are not interface methods and that do not provide implementations must be declared using keyword __________.

e. Casting a reference stored in a superclass variable to a subclass type is called __________.

G.4 State whether each of the statements that follows is true or false. If false, explain why.

a. All methods in an abstract class must be declared as abstract methods.


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint