The Java.util.EnumMap.get(Object key) method in Java is used to give the mapped value of the specified key.
Parameter: The method takes one parameter key which is passed to return the value associated with it.
Return Value: It returns the value mapped with the associated key.
Below programs illustrate the working of get() function:
GeeksforGeeks ranked in India: 72
Visitors in United_States: 18.2%
Attention reader! Don’t stop learning now. Get hold of all the important Java Foundation and Collections concepts with the Fundamentals of Java and Java Collections Course at a student-friendly price and become industry ready. To complete your preparation from learning a language to DS Algo and many more, please refer Complete Interview Preparation Course.