MCPcopy Index your code
hub / github.com/qiyuangong/leetcode / updateQueue

Method updateQueue

python/146_LRU_Cache.py:10–12  ·  view source on GitHub ↗
(self, key)

Source from the content-addressed store, hash-verified

8 self.queue = []
9
10 def updateQueue(self, key):
11 self.queue.remove(key)
12 self.queue.insert(0, key)
13
14 def get(self, key):
15 """

Callers 1

getMethod · 0.95

Calls 2

removeMethod · 0.45
insertMethod · 0.45

Tested by

no test coverage detected