Tutorial.java Source code

Java tutorial

Introduction

Here is the source code for Tutorial.java

Source

import java.util.EnumMap;
import java.util.HashMap;
import java.util.Map;

enum Tutorial {
    CSS, Python, PHP, Java, Javascript
};

public class Main {
    public static void main(String[] args) {
        Map m = new HashMap<Tutorial, String>();
        EnumMap<Tutorial, String> map = new EnumMap<Tutorial, String>(m);

        map.put(Tutorial.CSS, "1");
        map.put(Tutorial.Python, "2");
        map.put(Tutorial.PHP, "3");
        map.put(Tutorial.Java, "4");

        System.out.println(map.hashCode());

    }
}