找准目标,不断前行

循环Map

Map <String,String>map = new HashMap<String,String>();
map.put("aa", "aa");
map.put("bb", "bb");
for(Map.Entry<String, String> entry : map.entrySet()){
    String mapKey = entry.getKey();
    String mapValue = entry.getValue();
    System.out.println(mapKey + ":" + mapValue);
}

 

posted @ 2021-04-27 14:40  kevinZhuZhu  阅读(156)  评论(0编辑  收藏  举报