toTitleCase

JVM
1.0
fun Char.toTitleCase(): Char

Converts this character to titlecase.

import kotlin.test.*
import java.util.*

fun main(args: Array<String>) {
//sampleStart
val chars = listOf('a', 'Dž', '1', '+')
val titleCases = chars.map { it.toTitleCase() }
println(titleCases) // [A, Dž, 1, +]
//sampleEnd
}

See Also

Character.toTitleCase