Add implementation and new function for the hash table. Modifying prime management functions