Python Gelişmis hesap makinası örnek

defacerGLD

Profesör
Katılım
16 Ocak 2020
Mesajlar
3,317
Reaksiyon puanı
3,022
Puanları
293
Konum
Atamızın sevildiği her yer
bu kodlar size ne yapacağınızı az veya çok gösterir umarım
geliştirirsiniz umarım

Görüntü:
1.PNG


2.PNG

kodlar:
from math import *
from tkinter import *

def hesapla():
veri = kutu.get()
veri = str(veri)
if veri == "":
sonuc.config(text = "boş bırakma")
else:
isle = "global sonuc2;sonuc2 ="+veri
exec(isle)
print(isle,"\n",sonuc2)
sonuc.config(text = str(sonuc2))

help = Tk()
help.geometry("400x390+100+80")
help.title("defacerGLD")

sonuc = Label(help)
sonuc.config(text = "İşlemin\n", font = "bold 16",fg = "red")
sonuc.pack()

kutu = Entry(help)
kutu.pack()

buton = Button(help)
buton.config(text = "Hesapla",command = hesapla)
buton.pack()
mainloop()

gelistirmek için örneğin
help.geometry("400x390+100+80") yerine help.geometry("200x900+159+82")
gibi olabilir neyin ne olduğunu umarım göstermeye yetmiştir
 
Üst