Demonstrates a basic class and object : Class Definition : Class PYTHON TUTORIALS


PYTHON TUTORIALS » Class » Class Definition »

 

Demonstrates a basic class and object


class MyClass(object):
    def talk(self):
        print "an instance of class MyClass."

crit = MyClass()
crit.talk()



Leave a Comment / Note


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


PYTHON TUTORIALS

 Navioo Class
» Class Definition