Programming with Java, part 5
1.About Map of collection classFollowing List, this time I will introduce Map from the utility "java.util". You store a combination of key and value in Mapas one data. You use the key if you want to retrieve thevalue from the Map.Map also has several classes, so I will explain about"HashMap", "TreeMap", and "LinkedHashMap" in this time.(1)HashMapThis is a standard Map. You cannot register the duplicatekeys. Also, the elements (key and value sets) are notarranged in the order in which they were registered.To use it, specify the type as shown below when you new.For example, HashMap<String,String> map = new HashMap<String,String>();or HashMap<Integer,String> map = new HashMa
0