fixed typos

I tried trimming up invalid expressions without knowledge of Autocomplete and TRIE. Please read and merge this carefully. Thank you.