from tkinter import *
def clicked():
print("Клик")
window = Tk()
window.title("tk")
window.geometry('640x480')
btn = Button(window, text="Кликни на меня!", command=clicked,bg="blue",fg="black")
btn.pack(side=TOP)
window.mainloop()
from tkinter import *
def clicked():
print("Клик")
window = Tk()
window.title("tk")
window.geometry('640x480')
btn = Button(window, text="Кликни на меня!", command=clicked,bg="blue",fg="black")
btn.pack(side=TOP)
window.mainloop()