Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class A:
- y = 0
- def __init__(self):
- x = 0
- def test(self):
- y = 1
- instance = A
- print A.y #throws error 'no attribute'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement