Skip to content
Advertisement

Find max int key in hashmap kotlin

JavaScript

I have to find maximum Int key value of myDict HashMap. something like this:

JavaScript

Advertisement

Answer

You could do this :

JavaScript

Api reference : keys, maxOrNull()

User contributions licensed under: CC BY-SA
8 People found this is helpful
Advertisement