From Dev.to
Your Hand-Rolled LRU Cache Is One Edge Case Away from a Memory Leak
The bug You're asked to implement an LRU cache for decoded bitmap thumbnails in a coding round, or you class NaiveLruCache(private val capacity: Int) { private val map = LinkedHashMap(capacity,...
