Home > Back-end >  Java compareto method only why return value can be sorted
Java compareto method only why return value can be sorted

Time:12-09

Java compareto method only why return value can be sorted

CodePudding user response:

Because you call sort method can take advantage of the Comparable interface compareto method, are compared, and the element size as long as you can compare two elements size, no matter in that sorting algorithm, can be sorted
  • Related