โดยจะเรียกใช้ GUI (Tkinter) แล้วกำหนดตัวอักษรลงไปเพื่อกำหนดหัวข้อหน้าต่าง กำหนดขนาดของหน้าต่าง และกำหนด Hello world โดยใช้ Lable
โค้ด: เลือกทั้งหมด
from tkinter import *
root = Tk()
root.title("Hello example")
root.geometry("250x150")
w = Label(root, text="Hello world")
w.pack()
root.mainloop()
ข้อมูลจาก : Exploring Python.