LRU cache with TTL
You've implemented an LRU cache and the interviewer follows up: "Now make each entry expire a fixed time after it's stored. What gets more expensive?" Explain the cheapest way to check expiry and what that approach costs you.
LRU cache with TTL
You've implemented an LRU cache and the interviewer follows up: "Now make each entry expire a fixed time after it's stored. What gets more expensive?" Explain the cheapest way to check expiry and what that approach costs you.
PersistenceMultiple choiceBasics
You picked LRU for an image cache. Select all the correct statements about LRU.
#lru #cache #linked-list #hashmap
CS fundamentals and algorithmsShort answerAdvanced
You need to write an in-memory image cache with LRU eviction yourself. Which data structu…
#lru #cache #linked-list
PersistenceShort answerAdvanced
You're given 15 minutes to design a key-value store whose values carry an expiry time. se…
#ttl #cache
PersistenceShort answerBasics
NSCache exists, so why do image libraries write their own LRU cache?
#lru #linked-list