Reputation: 12044
Scala has scala.util.Sorting for sorting and Java also has sort method on collection. Are there any performance comparison between these two languages as far as sorting goes?
Upvotes: 0
Views: 235
Reputation: 19187
Documentation for the Sortingobject says that
These implementations are derived from those in the Sun JDK.
so I guess it is same quicksort and there should be no difference.
benchmark it yourself with small (less than 10 elements) and large (about 1 Mb of data) collections.
Upvotes: 2