how to print all values in a treemap code example
Example: java print treemap
for (Map.Entry<K, V> entry : myMap.entrySet()) {
System.out.println("Key: " + entry.getKey() + ". Value: " + entry.getValue());
}
for (Map.Entry<K, V> entry : myMap.entrySet()) {
System.out.println("Key: " + entry.getKey() + ". Value: " + entry.getValue());
}