#pack布局. py
import tkinter
root=tkinter.Tk()
root.geometry('300x200+300+300') #窗口的宽度x高度(x是小写的英文字母x不是*)
root.title('pack布局')
root.config(bg='#ccff00') #窗口的背景颜色
label=tkinter.Label(root,text='hello,python')
label.pack()
button1=tkinter.Button(root,text='BUTTON1')
button1.pack(side=tkinter.LEFT)
button2=tkinter.Button(root,text='BUTTON2')
button2.pack(side=tkinter.RIGHT)
root.mainloop()