Home
← All questions

Search suggestion cache that drops the oldest unused query

MediumJavaScript

Cache suggestion results by query string. When the cache is full, remove the query that has gone unused the longest before storing a new one.

Premium question

Unlock the full problem, starter code, and hidden test cases with Mentoxis Premium.

Unlock with Premium