首页 > 代码库 > LeetCode "460. LFU Cache" !

LeetCode "460. LFU Cache" !

My first try was very close to a final solution .. however, this is a much neater solution:

https://discuss.leetcode.com/topic/69436/concise-c-o-1-solution-using-3-hash-maps-with-explanation

Lesson learnt: data structure is crucial. And, if some logic is getting too complex, there must be sth wrong.

LeetCode "460. LFU Cache" !