java map out print code example Example: print map java map.forEach((key, value) -> System.out.println(key + ":" + value));