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

Method __init__

Solutions/7_1/validate.py:113–116  ·  view source on GitHub ↗
(self, name, shares, price)

Source from the content-addressed store, hash-verified

111 shares = PositiveInteger()
112 price = PositiveFloat()
113 def __init__(self, name, shares, price):
114 self.name = name
115 self.shares = shares
116 self.price = price
117
118 def __repr__(self):
119 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