Question
QUESTION 1 Polymorphism can simplify programming by enabling programs to process objects that share the same superclass as if they're all objects of the superclass.
QUESTION 1
-
Polymorphism can simplify programming by enabling programs to process objects that share the same superclass as if they're all objects of the superclass.
True or False?
QUESTION 2
-
A class uses the _____ keyword to indicate that it supports the specified interface.
satisfies
reifies
realizes
implements
QUESTION 3
-
A class that does not implement (directly or indirectly) all the methods of the interfaces it is declared to support must be declared as ______.
QUESTION 4
-
A _____ method cannot be overridden in a subclass.
QUESTION 5
-
A class that is declared final cannot be a superclass.
True or False?
QUESTION 6
-
You can determine if an object is of a particular type using the _______ operator.
QUESTION 7
-
Which of the following options is most likely to display the name of object obj's class?
System.out.print(obj.name);
System.out.print(obj.class.name);
System.out.print(obj.getName());
System.out.print(obj.getClass().getName());
System.out.print(obj.getClass.getName);
QUESTION 8
-
_______ classes cannot be directly instantiated and are intended for use only in inheritance hierarchies.
QUESTION 9
-
_______ classes are directly instantiable and provide an implementation for every method they declare.
QUESTION 10
-
An abstract class must contain at least one abstract method.
True or False?
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started