MCPcopy Create free account
hub / github.com/dabeaz-course/python-mastery / __init__

Method __init__

Solutions/7_4/validate.py:149–152  ·  view source on GitHub ↗
(self, name, shares, price)

Source from the content-addressed store, hash-verified

147 shares = PositiveInteger()
148 price = PositiveFloat()
149 def __init__(self, name, shares, price):
150 self.name = name
151 self.shares = shares
152 self.price = price
153
154 def __repr__(self):
155 return f'Stock({self.name!r}, {self.shares!r}, {self.price!r})'

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected