kotlin.collections.remove
remove
inline fun <T> MutableCollection<out T>.remove( element: T ): Boolean
Removes a single instance of the specified element from this collection, if it is present.
Allows to overcome type-safety restriction of remove
that requires to pass an element of type E
.
Return true
if the element has been successfully removed; false
if it was not present in the collection.
inline fun <K, V> MutableMap<out K, V>.remove(key: K): V?
Removes the specified key and its