6
public static <T extends Comparable<? super T>> T max(List<? extends T> coll){
    // return max;
}

I see why <T extends Comparable<? super T>> makes a sense. But, I am not sure why an argument List<? extends T> coll is important.

Why List<T> coll is not sufficient?

Zabuzard
  • 20,717
  • 7
  • 45
  • 67
Gilgamesz
  • 3,855
  • 2
  • 19
  • 47

0 Answers0