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

Method __init__

Solutions/4_4/stock.py:7–10  ·  view source on GitHub ↗
(self, name, shares, price)

Source from the content-addressed store, hash-verified

5 An instance of a stock holding consisting of name, shares, and price.
6 '''
7 def __init__(self, name, shares, price):
8 self.name = name
9 self.shares = shares
10 self.price = price
11
12 def cost(self):
13 '''

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected