Im creating a Hash Table with chaining with an array of STL list(s). My getNext function works but after calling the first function then getNext it gives me the same thing. Don't know why. Also when using my retrieve function how would I get the correct one at that location since Im using chaining. Also can I resize the array even if im using #define HASHTABLE_CAPACITY. I need to re-size when the load factor gets to a certain %
MY DataType is a struct
1 2 3 4 5
struct Node
{
string term, course, instructor;
};
I use term & course to get desired index then its wrapped if needed
Ive tried using an STL "it" iterator but to find the exact match I had to pass the same node in to find it which kind of seems stupid. Is there a way to find the correct one by using aNode.instructor to detemine the right one I want.
I know about STL Hash Tables but my teacher wants us to create our own. Sorry but not sure what you mean by "excessive". I used the "it" to find the correct one. Thanks for your help. I made an array of STL list so thats why I used the [].