import java.util.Hashtable;
public class MainClass {
public static void main(String[] s) {
Hashtable table = new Hashtable();
table.put("key1", "value1");
table.put("key2", "value2");
table.put("key3", "value3");
Hashtable table2 = new Hashtable();
table2.put("key4", "value4");
table2.put("key5", "value5");
table2.put("key6", "value6");
table2.putAll(table);
System.out.println(table2);
}
}
|