Skip to content
Advertisement

How to use a HashMap returned from a method

Here I have a program which creates a HashMap within a method

JavaScript

This program doesn’t work due to the fact that in the main method “abilities” cannot be found. How can I make it so I can use my HashMap in the main function.

Advertisement

Answer

JavaScript

Try it out

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