多项选择题
Given a class whose instances, when found in a collection of objects, are sorted by using the compareTo()method, which two statements are true?()
A.The class implements java.lang.Comparable.
B.The class implements java.util.Comparator.
C.The interface used to implement sorting allows this class to define only one sort sequence.
D.The interface used to implement sorting allows this class to define many different sort sequences.
点击查看答案
相关考题
-
单项选择题
Given: What is the result?()
A.0
B.1
C.2
D.3
E.4
F.Compilation fails.
G.An exception is thrown at runtime. -
单项选择题
Given: What is the result?()
A.7
B.49
C.343
D.Compilation fails.
E.An exception is thrown at runtime. -
单项选择题
Given: What is the result when the programmer attempts to compile the code and run it with the command java Converter 12?()
A. It is true that j==i.
B. It is false that j==i.
C. An exception is thrown at runtime.
D. Compilation fails because of an error in line 13.
