minOfWith

Common
JVM
JS
Native
1.4
inline fun <T, R> Array<out T>.minOfWith(
    comparator: Comparator<in R>,
    selector: (T) -> R
): R

(source)
inline fun <R> ByteArray.minOfWith(
    comparator: Comparator<in R>,
    selector: (Byte) -> R
): R

(source)
inline fun <R> ShortArray.minOfWith(
    comparator: Comparator<in R>,
    selector: (Short) -> R
): R

(source)
inline fun <R> IntArray.minOfWith(
    comparator: Comparator<in R>,
    selector: (Int) -> R
): R

(source)
inline fun <R> LongArray.minOfWith(
    comparator: Comparator<in R>,
    selector: (Long) -> R
): R

(source)
inline fun <R> FloatArray.minOfWith(
    comparator: Comparator<in R>,
    selector: (Float) -> R
): R

(source)
inline fun <R> DoubleArray.minOfWith(
    comparator: Comparator<in R>,
    selector: (Double) -> R
): R

(source)
inline fun <R> BooleanArray.minOfWith(
    comparator: Comparator<in R>,
    selector: (Boolean) -> R
): R

(source)
inline fun <R> CharArray.minOfWith(
    comparator: Comparator<in R>,
    selector: (Char) -> R
): R

(source)
@ExperimentalUnsignedTypes inline fun <R> UIntArray.minOfWith(
    comparator: Comparator<in R>,
    selector: (UInt) -> R
): R

(source)
@ExperimentalUnsignedTypes inline fun <R> ULongArray.minOfWith(
    comparator: Comparator<in R>,
    selector: (ULong) -> R
): R

(source)
@ExperimentalUnsignedTypes inline fun <R> UByteArray.minOfWith(
    comparator: Comparator<in R>,
    selector: (UByte) -> R
): R

(source)
@ExperimentalUnsignedTypes inline fun <R> UShortArray.minOfWith(
    comparator: Comparator<in R>,
    selector: (UShort) -> R
): R

(source)

Returns the smallest value according to the provided comparator among all values produced by selector function applied to each element in the array.

Exceptions

NoSuchElementException - if the array is empty.

Common
JVM
JS
Native
1.4
inline fun <T, R> Iterable<T>.minOfWith(
    comparator: Comparator<in R>,
    selector: (T) -> R
): R

(source)

Returns the smallest value according to the provided comparator among all values produced by selector function applied to each element in the collection.

Exceptions

NoSuchElementException - if the collection is empty.

Common
JVM
JS
Native
1.4
inline fun <K, V, R> Map<out K, V>.minOfWith(
    comparator: Comparator<in R>,
    selector: (Entry<K, V>) -> R
): R

(source)

Returns the smallest value according to the provided comparator among all values produced by selector function applied to each entry in the map.

Exceptions

NoSuchElementException - if the map is empty.