Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/dabeaz/python-cookbook
/ Stock
Class
Stock
src/8/simplified_initialization_of_data_structures/example1.py:14–15 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
12
# Example class definitions
13
if
__name__ ==
'__main__'
:
14
class
Stock(Structure):
15
_fields = [
'name'
,
'shares'
,
'price'
]
16
17
class
Point(Structure):
18
_fields = [
'x'
,
'y'
]
Callers
1
example1.py
File · 0.70
Calls
no outgoing calls
Tested by
no test coverage detected