X interview question

Search suggestion leetcode question (trie)