Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;

import java.util.Map;
import java.util.Set;

public class Main {
    public static void printMap(Map map) {
        Set<Map.Entry> entrySet = map.entrySet();
        for (Map.Entry entry : entrySet) {
            entry.getKey();
            entry.getValue();
            System.out.println(String.format("K: %s, V: %s", entry.getKey(), entry.getValue()));
        }
    }
}