NameTag class : Class Definition : Class PYTHON examples


PYTHON examples » Class » Class Definition »

 

NameTag class


 

class NameTag:
    def __init__(self, myname):
        self.myname = myname
    
    def say(self):
        print "Hello, my name is", self.myname

   
  



Leave a Comment / Note


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


PYTHON examples

 Navioo Class
» Class Definition