get

expect open operator override fun get(index: Int): Char(source)

Returns the character of this string at the specified index.

If the index is out of bounds of this string, throws an IndexOutOfBoundsException except in Kotlin/JS where the behavior is unspecified, and in Kotlin/Wasm where a trap will be raised instead, unless -Xwasm-enable-array-range-checks compiler flag was specified when linking an executable.

Since Kotlin

1.0
actual open operator override fun get(index: Int): Char(source)

Returns the character of this string at the specified index.

If the index is out of bounds of this string, the behavior is unspecified.

Since Kotlin

1.1
actual open operator override fun get(index: Int): Char(source)

Returns the character of this string at the specified index.

If the index is out of bounds of this string, throws an IndexOutOfBoundsException.

Since Kotlin

1.0
actual open operator external override fun get(index: Int): Char(source)

Returns the character of this string at the specified index.

If the index is out of bounds of this string, throws an IndexOutOfBoundsException.

Since Kotlin

1.3
actual open operator override fun get(index: Int): Char(source)

Returns the character of this string at the specified index.

In Kotlin/Wasm, a trap will be raised if the index is out of bounds of this string, unless -Xwasm-enable-array-range-checks compiler flag was specified when linking an executable. With -Xwasm-enable-array-range-checks flag, IndexOutOfBoundsException will be thrown.

Since Kotlin

1.8
actual open operator override fun get(index: Int): Char(source)

Returns the character of this string at the specified index.

In Kotlin/Wasm, a trap will be raised if the index is out of bounds of this string, unless -Xwasm-enable-array-range-checks compiler flag was specified when linking an executable. With -Xwasm-enable-array-range-checks flag, IndexOutOfBoundsException will be thrown.

Since Kotlin

1.8