clear
Removes all elements from this collection.
Since Kotlin
1.4Samples
import kotlin.math.*
import kotlin.test.*
fun main() {
//sampleStart
val collection: MutableCollection<Char> = mutableSetOf('a', 'b', 'c')
println(collection) // [a, b, c]
collection.clear()
println(collection) // []
//sampleEnd
}