Ushbu dastur python dasturi bo'yicha ishlangan.Unda siz ayrim pul birliklarini o'zbek so'mida qancha bo'lishini bilib olasiz
Просмотр содержимого документа
«Работа с PYTHON»
Работа с ткинтер
from tkinter import*
import tkinter
w=Tk()
w.geometry('600x500')
w.titlfrom tkinter import*
import tkinter
w=Tk()
w.geometry('600x500')
w.title('spinbox')
lb1=Label(w,text='Pul birligingiz nima')
lb1.pack()
sp=Spinbox(w,value=("dollar","rubl","evro","dirham","funt"),width=40)
sp.pack()
lb2=Label(w,text='Qancha pul ayirboshlamoqchisiz: ')
lb2.pack()
ent=Entry(w,width=30)
ent.pack()
def bajar():
a=sp.get()
if a=='dollar': k=11800
if a=='rubl': k=150
if a=='evro': k=12600
if a=='dirham': k=1.61
if a=='funt': k=15500
b=int(ent.get())
ok.config(text=b*k)
Button(w,text='Sizning Pulingiz',command=bajar).pack()
ok=Label(w,text='Javobi')
ok.pack()
w.mainloop()e('spinbox')
lb1=Label(w,text='Pul birligingiz nima')
lb1.pack()
sp=Spinbox(w,value=("dollar","rubl","evro","dirham","funt"),width=40)
sp.pack()
lb2=Label(w,text='Qancha pul ayirboshlamoqchisiz: ')
lb2.pack()
ent=Entry(w,width=30)
ent.pack()
def bajar():
a=sp.get()
if a=='dollar': k=11800
if a=='rubl': k=150
if a=='evro': k=12600
if a=='dirham': k=1.61
if a=='funt': k=15500
b=int(ent.get())
ok.config(text=b*k)
Button(w,text='Sizning Pulingiz',command=bajar).pack()
ok=Label(w,text='Javobi')
ok.pack()
w.mainloop()