diff options
Diffstat (limited to 'wk5/pset')
-rw-r--r-- | wk5/pset/speller/dictionary.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/wk5/pset/speller/dictionary.c b/wk5/pset/speller/dictionary.c index b550e36..b0d1323 100644 --- a/wk5/pset/speller/dictionary.c +++ b/wk5/pset/speller/dictionary.c @@ -67,8 +67,11 @@ bool load(const char *dictionary) } // copy word from fscanf into node using strcpy strcpy(ptr->word, word); + // set the new ptr ptr->next = NULL; + // hash the word to find the bucket it goes in int val = hash(word); + // if (table(val)->next != NULL) { char = 0; |