fun <T> Array<T>.reverse()
fun ByteArray.reverse()
fun ShortArray.reverse()
fun IntArray.reverse()
fun LongArray.reverse()
fun FloatArray.reverse()
fun DoubleArray.reverse()
fun BooleanArray.reverse()
fun CharArray.reverse()
@ExperimentalUnsignedTypes fun UIntArray.reverse()
@ExperimentalUnsignedTypes fun ULongArray.reverse()
@ExperimentalUnsignedTypes fun UByteArray.reverse()
@ExperimentalUnsignedTypes fun UShortArray.reverse()
Reverses elements in the array in-place.
fun <T> Array<T>.reverse(fromIndex: Int, toIndex: Int)
fun ByteArray.reverse(fromIndex: Int, toIndex: Int)
fun ShortArray.reverse(fromIndex: Int, toIndex: Int)
fun IntArray.reverse(fromIndex: Int, toIndex: Int)
fun LongArray.reverse(fromIndex: Int, toIndex: Int)
fun FloatArray.reverse(fromIndex: Int, toIndex: Int)
fun DoubleArray.reverse(fromIndex: Int, toIndex: Int)
fun BooleanArray.reverse(fromIndex: Int, toIndex: Int)
fun CharArray.reverse(fromIndex: Int, toIndex: Int)
@ExperimentalUnsignedTypes fun UIntArray.reverse( fromIndex: Int, toIndex: Int)
@ExperimentalUnsignedTypes fun ULongArray.reverse( fromIndex: Int, toIndex: Int)
@ExperimentalUnsignedTypes fun UByteArray.reverse( fromIndex: Int, toIndex: Int)
@ExperimentalUnsignedTypes fun UShortArray.reverse( fromIndex: Int, toIndex: Int)
Reverses elements of the array in the specified range in-place.
fromIndex
- the start of the range (inclusive) to reverse.
toIndex
- the end of the range (exclusive) to reverse.
IndexOutOfBoundsException
- if fromIndex is less than zero or toIndex is greater than the size of this array.
IllegalArgumentException
- if fromIndex is greater than toIndex.
fun <T> MutableList<T>.reverse()
Reverses elements in the list in-place.
© 2010–2020 JetBrains s.r.o. and Kotlin Programming Language contributors
Licensed under the Apache License, Version 2.0.
https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/reverse.html