Skip to content

Instantly share code, notes, and snippets.

@minghan minghan/property.py
Created Jul 12, 2011

Embed
What would you like to do?
Using @Property
# Using @property
class Pakrox(object):
def __init__(self):
self._pak = 10
@property
def pak(self):
return self._pak
p = Pakrox()
print p.pak
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.