Error:
do not know how to do:
- use new concept call Trie, which 1) use less space to store string and 2) faster to search, O(h) time, 3) it can search prefix.
- It like a tree to create a path for each string/word.
- always remember we begin with root node, not the first char of string!!
update:
1. need to remember the struct of Trie:
- Node{ bool is_word, vector<Node*> next(26, nullptr)};
2. for search, need to use dfs to finish.