Kotlin HashMap set()
Syntax & Examples


Syntax of HashMap.set()

The syntax of HashMap.set() extension function is:

operator fun <K, V> MutableMap<K, V>.set(key: K, value: V)

This set() extension function of HashMap allows to use the index operator for storing values in a mutable map.