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

Method sell

Solutions/7_3/stock.py:15–16  ·  view source on GitHub ↗
(self, nshares: PositiveInteger)

Source from the content-addressed store, hash-verified

13 return self.shares * self.price
14
15 def sell(self, nshares: PositiveInteger):
16 self.shares -= nshares

Callers 1

test_sellMethod · 0.95

Calls

no outgoing calls

Tested by 1

test_sellMethod · 0.76