Вот код:
import tkinter as tk win = tk.Tk() win.geometry('600x600+400+80') win.resizable(False, False) def X_O(e): print(e.widget.grid_info()['row'],e.widget.grid_info()['column']) def FuncF(): Man.pack_forget() for i in range(10): for j in range(10): b = tk.Button(win, text = ' ') b.bind('<Button-1>',X_O) b.grid(row=j,column=i,stick='nswe') win.grid_columnconfigure({j}, minsize = 60) win.grid_rowconfigure({j}, minsize = 60) Man = tk.Button( win, text = '', command = FuncF, font = ('Arial','25','bold italic'), relief = tk.RAISED, bd = 10, activebackground = '#8B008B') Man.pack(pady = 20 ) win.mainloop()