Implement an LRU cache (least recently used cache).
Anónimo
Using Python OrderedDict with the move to head as usual. Did 10 min of testing to prove that my solution worked, until the interviewer agreed. So something about my solution (using OrderedDict instead of raw doubly linked lists?) or my lack of usage of ChatGPT/google to get direct answer led to a failure maybe (was I too slow?)