Practice
Learn
← Quit
0 / 0 correct
Data Structures
Hard
1 of 40
How do you implement an LFU cache with O(1) operations?
A
A key→node map plus a map from frequency to a doubly linked list of keys, tracking the minimum frequency
B
A sorted array of counts
C
A single queue
D
A min-heap of frequencies (O(log n))