import tkinter def cb(msg): print(msg) btn = ['hui', 'pizda'] top = tkinter.Tk() for b in btn: bo = tkinter.Button(top, text=b, command=lambda param=b: cb(param)) bo.pack() top.mainloop()
Standard input is empty
Standard output is empty
Traceback (most recent call last): File "./prog.py", line 1, in <module> ModuleNotFoundError: No module named 'tkinter'