Comparable interface in java
Let’s learn what is comparable interface in java? Comparable interface in java Comparable interface is an interface used to compare objects of same type. It can be implemented by any custom class and is found in java.lang package. Declaration: public interface Comparable<T> Parameters: <T> the type of objects that this object may be compared to…
Read More Comparable interface in java