Use Caution When Accessing Class Attribute with Instance : Attribute : Class PYTHON TUTORIALS


PYTHON TUTORIALS » Class » Attribute »

 

Use Caution When Accessing Class Attribute with Instance


class Foo(object):
     x = 1.5

foo = Foo()
print foo.x
foo.x = 1.7          
print foo.x            
print Foo.x



Leave a Comment / Note


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


PYTHON TUTORIALS

 Navioo Class
» Attribute