import tkinter top = tkinter.Tk() def helloCallBack(): print("kuku") def helloCallBack2(): print("kuku2") B = tkinter.Button(top, text ="Hello", command = helloCallBack) B2 = tkinter.Button(top, text ="Hello2", command = helloCallBack2) B.pack() B2.pack() top.mainloop()