SmallestComparator<T> extension

on

Methods

smallest(Iterable<T> iterable, int k) List<T>

Available on Comparator<T>, provided by the SmallestComparator extension

Returns a list of the k smallest elements from the given iterable according to this ordering, in order from smallest to largest.