Frage im Vorstellungsgespräch bei AppDynamics

Write code to implement a LRU cache with eviction

Antworten zu Vorstellungsgespräch

Anonym

17. Dez. 2018

use combination of doubly link list(for adding(at head O(1)) and deleting node(from rearO(1))) with unordered_map (for node in O(1) time)

1

Anonym

18. Juli 2018

I implemented it using a map and a backing queue.