Created
October 12, 2020 12:52
-
-
Save ch8n/08818e0fb1ea6af24c70b6354d2c6b31 to your computer and use it in GitHub Desktop.
no direct conversion
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// you need to first convert to map | |
mutableListOf<Pair<String,Int>>(pair,updatedPair).toMap() | |
// then you have access to mutableMap extension | |
mutableListOf<Pair<String,Int>>(pair,updatedPair).toMap().toMutableMap() | |
//signature | |
fun <K, V> Map<out K, V>.toMutableMap(): MutableMap<K, V> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment