MCPcopy Create free account
hub / github.com/bslatkin/effectivepython / MultiplyNode

Class MultiplyNode

example_code/item_049.py:123–131  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

121 return left + right
122
123class MultiplyNode(Node):
124 def __init__(self, left, right):
125 self.left = left
126 self.right = right
127
128 def evaluate(self):
129 left = self.left.evaluate()
130 right = self.right.evaluate()
131 return left * right
132
133
134print("Example 9")

Callers 1

item_049.pyFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected