Return the cost as shares*price
(self)
| 13 | return f'Stock({self.name!r}, {self.shares!r}, {self.price!r})' |
| 14 | |
| 15 | def cost(self): |
| 16 | ''' |
| 17 | Return the cost as shares*price |
| 18 | ''' |
| 19 | return self.shares * self.price |
| 20 | |
| 21 | def sell(self, nshares): |
| 22 | ''' |