The Comparable interface is a functional interface that contains
one method that takes one parameter. Which of the below is true
regarding how a class implements that one method? Choose ALL that
apply.
A. The method is expected to return a negative number if that
instance should be ordered after the parameter.
B. It should return a positive number if that object should be
ordered after the parameter
C. It should return a zero if that instance is equal to the
parameter
D. It should return the String value "less" if it should be
ordered before the parameter
The Comparable interface is a functional interface that contains one method that takes one parameter. Which of the below
-
answerhappygod
- Site Admin
- Posts: 899604
- Joined: Mon Aug 02, 2021 8:13 am
The Comparable interface is a functional interface that contains one method that takes one parameter. Which of the below
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!