技术栈

leetcode周赛390

Espresso Macchiato
1 年前
字典树·leetcode hard·trie树·leetcode 3093·leetcode周赛390
Leetcode 3093. Longest Common Suffix Queries这一题的话思路上其实就是一个Trie树的变体。对于每一个wordsQuery当中的word,我们要在wordsContainer当中获取答案,我们只需要将wordsContainer构建成一个Trie树,就能够快速地获得我们所需的答案了。