mirror of
https://github.com/donnemartin/system-design-primer.git
synced 2025-09-18 10:00:38 +03:00
Merge 430fad549d
into 40d5d2edcc
This commit is contained in:
@@ -159,7 +159,7 @@ class Cache(object):
|
|||||||
self.lookup = {} # key: query, value: node
|
self.lookup = {} # key: query, value: node
|
||||||
self.linked_list = LinkedList()
|
self.linked_list = LinkedList()
|
||||||
|
|
||||||
def get(self, query)
|
def get(self, query):
|
||||||
"""Get the stored query result from the cache.
|
"""Get the stored query result from the cache.
|
||||||
|
|
||||||
Accessing a node updates its position to the front of the LRU list.
|
Accessing a node updates its position to the front of the LRU list.
|
||||||
|
Reference in New Issue
Block a user