Prefix Tree & Trie

O(log(L)) for insert one word

642. Design Search Autocomplete System

Method Related Questions
Recursion and trie 212. Word Search II