MCPcopy
hub / github.com/Jack-Lee-Hiter/AlgorithmsByPython / isRoot

Method isRoot

AVL.py:22–23  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

20 return self.parent and self.parent.rightChild == self
21
22 def isRoot(self):
23 return not self.parent
24
25 def isLeaf(self):
26 return not (self.rightChild or self.leftChild)

Callers 2

rotateLeftMethod · 0.45
rotateRightMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected