complexitystringstrees
A trie is useful when prefixes matter
Anonymous
a trie follows one edge per character in the prefix, then visits matching descendants. that makes prefix lookup depend on prefix length plus the output size, not on scanning every key. the tradeoff is memory: paths with little shared prefix can use many nodes.
0