Instance Attributes versus Class Attributes : Attribute : Class PYTHON TUTORIALS


PYTHON TUTORIALS » Class » Attribute »

 

Instance Attributes versus Class Attributes


# Access to Class Attributes

class C(object):     
     version = 1.2   

c = C()                    
print C.version      
print c.version      
print C.version      
print c.version



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .


PYTHON TUTORIALS

 Navioo Class
» Attribute