Intel Corporation interview question

How to implement LRU Cache with getting, adding and removing O(1)?

Interview Answer

Anonymous

8 Nov 2021

Map from key to pointer to object in a double sided linked list with a pointer to the head (MRU) and tail (LRU)