sortedWith
fun <T> Iterable<T>.sortedWith(vararg selectors: (T) -> Comparable<*>): List<T>
Content copied to clipboard
fun <T> Sequence<T>.sortedWith(vararg selectors: (T) -> Comparable<*>): Sequence<T>
Content copied to clipboard
Returns a list of all elements sorted according to the specified selectors.
The sort is stable. It means that equal elements preserve their order relative to each other after sorting.