dictionary.c
// iterate over the list at the hash of s and then strcmp
// and attempt to find s
iterate over the list at the hash of s and then strcmp
and attempt to find s
iterate over the list at the hash of s and then strcmp and attempt to find s
entry_t* lookup(dictionary_t dict, char* s) {
    entry_t* e;
    for (e = dict[hash(s)]; e != NULL; e = e->next) {
        if (strcmp(s, e->key) == 0) {
            return e;
        }
    }
    fprintf(stderr, "Key: %s not found\n", s);
    return NULL;
}
entry_t * lookup ( dictionary_t dict , char * s ) { entry_t * e ; for ( e = dict [ hash ( s ) ] ; e != NULL ; e = e -> next ) { if ( strcmp ( s , e -> key ) == 0 ) { return e ; } } fprintf ( stderr , " \n " , s ) ; return NULL ; }
iterate over the list at the hash of s and then strcmp
and attempt to find s
iterate over the list at the hash of s and then strcmp and attempt to find s
// If not found