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

Method sell

Solutions/9_2/stock.py:14–15  ·  view source on GitHub ↗
(self, nshares: PositiveInteger)

Source from the content-addressed store, hash-verified

12 return self.shares * self.price
13
14 def sell(self, nshares: PositiveInteger):
15 self.shares -= nshares
16
17if __name__ == '__main__':
18 from structly.reader import read_csv_as_instances

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected