// Test put public class Demo2 { public static void main(String[] args) { Dictionary H = new HashTableSC<>(5); System.out.println(H); H.put("ice", "cold"); H.put("fire", "hot"); H.put("rock", "hard"); H.put("wool", "soft"); H.put("sun", "hot"); System.out.println("\nInitial hash table:"); System.out.print(H); System.out.println("#Items = " + H.size() + "\n\n"); System.out.println("\nTest remove():"); System.out.println("-- ice:" + H.remove("ice")); System.out.print(H); System.out.println("#Items = " + H.size() + "\n"); System.out.println("-- fire:" + H.remove("fire")); System.out.print(H); System.out.println("#Items = " + H.size() + "\n"); System.out.println("-- sun:" + H.remove("sun")); System.out.print(H); System.out.println("#Items = " + H.size() + "\n"); } }