MCPcopy Index your code
hub / github.com/BeeBombshell/Python-DSA / appendleft

Method appendleft

DSA/deque.py:36–41  ·  view source on GitHub ↗
(self, x)

Source from the content-addressed store, hash-verified

34 self.tail %= self.length
35
36 def appendleft(self, x):
37 if self.is_full():
38 self.__extend()
39 self.buf[(self.head - 1) % self.length] = x
40 self.head -= 1
41 self.head %= self.length
42
43 def pop(self):
44 if self.is_empty():

Callers

nothing calls this directly

Calls 2

is_fullMethod · 0.95
__extendMethod · 0.95

Tested by

no test coverage detected