1. Iterator 사용
Set set = testMap.entrySet();
Iterator it = set.iterator();
while(it.hasNext()) {
Map.Entry me = (Map.Entry)it.next();
System.out.print("### testMap : "+me.getKey()+" - "+ me.getValue() +"\n");
}
2. 개선된 for문 사용 (enhanced for loop)
Map<String, Integer> map = new HashMap<String, Integer>();
map.put("A", 100);
map.put("B", 200);
for(Map.Entry<String, Integer> e : map.entrySet()) {
System.out.println(e.getKey() + ":" + e.getValue());
}