Skip to content
Hard Design: Search Autocomplete (Google)

What is the 'top-K cache at each node' optimization in a trie?

— Tests your understanding of this concept.

Answer Options

A Caching recently accessed trie nodes
B Pre-computing and storing the top 5 most frequent queries under each prefix node
C Limiting trie depth to K levels
D Caching the K most recently searched queries globally

Want to see the correct answer?

Get the answer with a detailed explanation, plus practice 22+ more Design: Search Autocomplete (Google) questions with adaptive quizzes and timed interviews.

See the Answer on Guru Sishya →

This question is from the Design: Search Autocomplete (Google) topic (System Design Cases).

More Design: Search Autocomplete (Google) Questions