@@ -0,0 +1,1162 @@
+import java.util.HashMap;%0Aimport java.util.Map;%0Aimport java.util.Iterator;%0Aimport java.util.Set;%0Aclass Details %7B%0A%0A   public static void main(String args%5B%5D) %7B%0A%0A      HashMap%3CInteger, String%3E hmap = new HashMap%3CInteger, String%3E();%0A%0A      hmap.put(12, %22Delhi%22);%0A      hmap.put(2, %22Mumbai%22);%0A      hmap.put(7, %22Banglore%22);%0A      hmap.put(49, %22Jaipur%22);%0A      hmap.put(3, %22Kolkata%22);%0A%0A      Set set = hmap.entrySet();%0A      Iterator iterator = set.iterator();%0A      while(iterator.hasNext()) %7B%0A         Map.Entry mentry = (Map.Entry)iterator.next();%0A         System.out.print(%22key is: %22+ mentry.getKey() + %22 & Value is: %22);%0A         System.out.println(mentry.getValue());%0A      %7D%0A%0A      String var= hmap.get(2);%0A      System.out.println(%22Value at index 2 is: %22+var);%0A%0A      hmap.remove(3);%0A      System.out.println(%22Map key and values after removal:%22);%0A      Set set2 = hmap.entrySet();%0A      Iterator iterator2 = set2.iterator();%0A      while(iterator2.hasNext()) %7B%0A          Map.Entry mentry2 = (Map.Entry)iterator2.next();%0A          System.out.print(%22Key is: %22+mentry2.getKey() + %22 & Value is: %22);%0A          System.out.println(mentry2.getValue());%0A       %7D%0A%0A   %7D%0A%7D%0A

Create hashmap_demo.java