Paths Subjects Questions Quizzes Pricing Search
Algorithms & Data Structures Intermediate Pro

Tries

Store a dictionary as a tree of characters and turn prefix queries into a single walk

25 min read 0 views

Learn the trie (prefix tree) data structure: how it represents a set of strings as a tree of shared prefixes, why that makes prefix and wildcard queries fast, and how to combine it with DFS/backtracking to search a 2D board of letters. Covers implementing a trie from scratch, wildcard search with '.', and multi-word board search.

Practice questions (3)

  • Design a Trie

    Intermediate
    View →
  • Insert and Search Words with Wildcards

    Advanced
    View →
  • Find All Words on a Board

    Advanced
    View →

We use cookies for product analytics to improve OmniAtlas. See our Privacy Policy.