completed functions in dictionary.c