Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

hashmap get value java


//Import Hashmap
import java.util.HashMap;
   
    HashMap<String, String> dir = new HashMap<String, String>();
//Add key, values  
    dir.put("hi", "hello");
	dir.put("wow", "amazing");
//print value for hi.
    System.out.println(dir.get("hi");
Source by www.programiz.com #
 
PREVIOUS NEXT
Tagged: #hashmap #java
ADD COMMENT
Topic
Name
4+1 =