code for t9 dictionary.