[Feature Request] Provide implementation for LRU cache
Closed this issue · 2 comments
Ernyoke commented
Least recently used (LRU) cache is a data structure which provides O(1) time access for any stored value based on a key, while having the ability to provide an O(1) access to the last used value as well. The size of the cache is limited, when this limit is reached, the oldest values will be evicted.
A possible implementation for this data structure can be found in this PR: #4
Depending on your choice, it could be merged, or you could discard it and use it as a basis of a possible future implementation.
esimov commented
Thanks a lot for your contribution. I don't have access to the code right now, but I will check it as soon as I can.