Programming - Interfaces
You Are Here :: Home > JAVA > Interfaces - General Questions
19.
A class uses the implements keyword to implement an interface.
A.
Interface
B.
Abstraction
C.
Encapsulation
D.
Inheritance
Answer: Option A
Explanation:
A class uses the implements keyword to implement an interface.
20.
Checked exceptions should not be declared on implementation methods other than the ones declared by the interface method or subclasses of those declared by the interface method.
A.
Interface
B.
Abstraction
C.
Encapsulation
D.
Inheritance
Answer: Option A
Explanation:
Checked exceptions should not be declared on implementation methods other than the ones declared by the interface method or subclasses of those declared by the interface method.
21.
The signature of the _____________ method and the same return type or subtype should be maintained when overriding the methods.
A.
Interface
B.
Abstraction
C.
Encapsulation
D.
Inheritance
Answer: Option A
Explanation:
The signature of the interface method and the same return type or subtype should be maintained when overriding the methods.
22.
An implementation class itself can be _______________ and if so interface methods need not be implemented.
A.
Abstract
B.
Static
C.
Non-Static
D.
Parameterized
Answer: Option A
Explanation:
An implementation class itself can be abstract and if so interface methods need not be implemented.
23.
The ___________ keyword is used to extend an interface
A.
this
B.
extends
C.
super
D.
get
Answer: Option B
Explanation:
The extends keyword is used to extend an interface
24.
An interface with no methods in it is referred to as a ______________ interface.
A.
tagging
B.
Static
C.
Non-Static
D.
Parameterized
Answer: Option A
Explanation:
An interface with no methods in it is referred to as a tagging interface.
« prev
next »