Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
Interfaces Worksheet
Directions: Mark the letter of the best answer to each question.
____ 1. A class that implements Comparable must implement how many methods at minimum?
a. 0
b. 1
c. 2
d. 3
e. 4
____ 2. A class that implements Wile must implement how many methods at minimum?
a. 0
b. 1
c. 2
d. 3
e. 4
____ 3. All methods located inside of an interface are automatically set with what access?
a. public
b. private
c. protected
d. A and B only
e. A, B, and C
1
____ 4. Which of the following could fill <blank 1>?
a. double getScore();
b. public double getScore();
c. public abstract double getScore();
d. A and B only
e. A, B, and C
____ 6. All variables located inside of an interface are automatically set with what access?
a. public
b. private
c. protected
d. A and B only
e. A, B, and C
____ 7. All variables located inside of an interface are automatically labeled with which of the
following modifiers?
a. static
b. abstract
c. final
d. A and C only
e. C only
2
____ 8. Which of the following could fill <blank 1>?
a. int x;
b. int x = 2.6;
c. double y = 29;
d. B and C only
e. A, B, and C
a. final int x;
b. final int x = 3.6;
c. final double y = 39;
d. B and C only
e. A, B, and C