
from tkinter import *
    
class TouchyButton:

    def __init__(self):
        self.root = Tk()
        self.label = Label(self.root, text = '')
        self.button = Button(self.root, text = "Push me!",
                             command = self.respondToPush)
        self.button.pack()
        self.label.pack()
        self.root.mainloop() #Message loop

    def respondToPush(self):
        if self.label['text'] == '': self.label['text'] = "Not so hard!"
        else: self.label['text'] = ''

if __name__ == '__main__':
    TouchyButton()
    TouchyButton()
    
    
    
