Complete the sentence to explain why tries are useful for prefix operations.
Tries are data structures that allow fast [1] of words based on their prefixes.Tries are designed to quickly search words by their prefixes, making prefix operations efficient.
Complete the sentence to describe how tries store words.
In a trie, each node represents a [1] of a word, allowing shared prefixes to be stored once.Each node in a trie represents a letter of a word, so common prefixes share nodes.
Fix the error in the explanation about tries and prefix search.
Tries optimize prefix search by storing each word separately without sharing [1].The error is that tries do share prefixes among words, which is why they optimize prefix search.
Fill both blanks to complete the explanation of tries' efficiency.
Because tries store words by [1] and share common [2], prefix searches are faster than scanning all words.
Tries store words by letters and share common prefixes, making prefix searches efficient.
Fill all three blanks to explain why tries are preferred for prefix operations.
Tries reduce [1] by sharing [2] among words and allow [3] prefix queries in time proportional to prefix length.
Tries reduce memory by sharing prefixes among words and allow fast prefix queries proportional to prefix length.