Fixed bugs to Dictionary Classes

This commit is contained in:
2014-05-17 23:17:11 +02:00
parent 4dab60c3fa
commit f1e6f18939
6 changed files with 96 additions and 39 deletions

View File

@@ -17,7 +17,7 @@ public class ChainingHashTableTest {
public static void main(String[] args) throws InvalidKeyException{
ChainingHashTable<String,Integer> h = new ChainingHashTable<String, Integer>();
ChainingHashTable<String,Integer> h = new ChainingHashTable<String, Integer>(1);
System.out.println(h.load_factor());

View File

@@ -17,7 +17,8 @@ public class LinearProbingHashTableTest {
public static void main(String[] args) throws InvalidKeyException{
LinearProbingHashTable<String,Integer> h = new LinearProbingHashTable();
LinearProbingHashTable<String,Integer> h = new LinearProbingHashTable(1);
System.out.println(h.load_factor());
@@ -89,12 +90,15 @@ public class LinearProbingHashTableTest {
Entry<String,Integer> f = h.insert("7", 100);
System.out.println(h);
h.remove(f);
System.out.println(h);
}
}