Çevirici I

  |   Kaynak

Bu kodlamada büyük yanlışlıklar var olabilir.

#!/usr/bin/env python

-- coding:utf-8 --

print  "      Ölçü Birimleri Çevirme Programı'na Hoşgeldiniz!!!"
anamenu1=" (a) Uzunluk Ölçü Birimleri"
anamenu2=" (b) Alan Ölçü Birimleri"
anamenu3=" (c) Ağırlık Ölçü Birimleri"
anamenu4=" (d) Hacim Ölçüleri"
anamenu5=" (e) Tartılar"
secenek1=" (a1) santimetre'cm' >>>>>>>>>>> inç"
secenek2=" (a2) metre'm' >>>>>>>>>>>>>>> yarda"
secenek3=" (a3) kilometre'km' >>>>>>>>>>>> mil"
secenek4=" (a4) inç >>>>>>>>>>> Santimetre'cm'"
secenek5=" (a5) ayak'foot' >>>> santimetre'cm'"
secenek6=" (a6) yarda >>>>>>>>>>>>>>> metre'm'"
secenek7=" (a7) karamili >>>>>>>>>>>> metre'm'"
secenek8=" (a8) denizmili >>>>>>>>>>> metre'm'"
secenek9=" (b1) santimetrekare'cm2'>>> inçkare"
secenek10=" (b2) metrekare(m2) >>>> yarda kare"
secenek11=" (b3) hektar'ha' >>>>>>>>>>>>> acre"
secenek12=" (b4) kilometrekare >>>>>> mil kare"
secenek13=" (b5) inç kare >>>>>>>>>>>>>> 'cm2'"
secenek14=" (b6) ayak kare >>>>>>>>>>>>> 'cm2'"
secenek15=" (b7) yarda kare >>>>>>>>>>>>> 'm2'"
secenek16=" (b8) acre >>>>>>>>>>>>>>>>>>> 'm2'"
secenek17=" (b9) mil kare >>>>>>>>>>>>> hektar"
secenek18=" (c1) gram'gr' >>>>>>>>>>>>>> ounce"
secenek19=" (c2) kilogram'kg' >>>>>>>>>> pound"
secenek20=" (c3) ton >>>>>>>>>>>>>>> küçük ton"
secenek21=" (c4) onunce'oz' >>>>>>>> gram 'gr'"
secenek22=" (c5) pound'Ib' >>>>> kilogram 'kg'"
secenek23=" (c6) küçük ton >>>>>>>>>>>>>>> ton"
secenek24=" (c7) büyük ton >>>>>>>>>>>>>>> ton"
secenek25=" (d1) santimetre küp'cm3'>>>inç küp"
secenek26=" (d2) desimetre küp'dm3'>>>ayak küp"
secenek27=" (d3) metre küp'm3'>>>>>>>yarda küp"
secenek28=" (d4) inç küp>>>>>>>>>>>>>>>>>'cm3'"
secenek29=" (d5) ayak küp>>>>>>>>>>>>>>>>'dm3'"
secenek30=" (d6) yarda küp>>>>>>>>>>>>>>>>'m3'"
secenek31=" (e1) litre'lt'>>>>>>>>>>'galon'ABD"
secenek32=" (e2) hektolitre'hl'>>>>'bushel'ABD"
secenek33=" (e3) 'pint-kuru'ABD>>>>>>>>'litre'"
secenek34=" (e4) 'pint-yat'ABD>>>>>>>>>'litre'"
secenek35=" (e5) 'pint'İngiliz>>>>>>>>>'litre'"
secenek36=" (e6) 'bushel'ABD>>>>>>>>>>>'litre'"
secenek37=" (e7) 'bushel'İngiliz>>>>>>>'litre'"
secenek38=" (e8) 'galon'ABD>>>>>>>>>>>>'litre'"
secenek39=" (e9) 'galon'İngiliz>>>>>>>>'litre'"
print anamenu1
print anamenu2
print anamenu3
print anamenu4
print anamenu5
soru0=raw_input("Lütfen işlem yapacağınız genel birimin kodunu girin: ")
if soru0=="a":
print "Uzunluk Ölçü Birimleri"
print secenek1,secenek2
print secenek3,secenek4
print secenek5,secenek6
print secenek7,secenek8
if soru0=="b":
print "Alan Ölçü Birimleri"
print secenek9,secenek10
print secenek11,"",secenek12
print secenek13,"",secenek14
print secenek15,"",secenek16
print secenek17
if soru0=="c":
print "Ağırlık Ölçü Birimleri"
print secenek18,"",secenek19
print secenek20,"",secenek21
print secenek22,"",secenek23
print secenek24
if soru0=="d":
print "Hacim Ölçüleri"
print secenek25,secenek26
print secenek27,secenek28
print secenek29,secenek30
if soru0=="e":
print "Tartılar"
print secenek31,secenek32
print secenek33,secenek34
print secenek35,secenek36
print secenek37,secenek38
print secenek39
while True:
aciklama="Lütfen sayısal değeri girin: "
soru=raw_input("Lütfen çeviri yapacağınız birimin numarasını girin: ")
if soru=="a1":
soru1=input(aciklama)
i=soru10.3937
print soru1,"cm"," :", i," inch"
if soru=="a2":
soru2=input(aciklama)
y=soru21.0936
print soru2,"m"," :",y," yarda"
if soru=="a3":
soru3=input(aciklama)
mil=soru30.6214
print soru3,"km"," :",mil," mil"
if soru=="a4":
soru4=input(aciklama)
s=soru42.5400
print soru4,"İnç"," :",s," cm"
if soru=="a5":
soru5=input(aciklama)
f=soru50.3048
print soru5,"foot"," :",f," cm"
if soru=="a6":
soru6=input(aciklama)
me=soru60.9144
print soru6,"yarda"," :",me," m"
if soru=="a7":
soru7=input(aciklama)
met=soru71609
print soru7,"karamili"," :",met," m"
if soru=="a8":
soru8=input(aciklama)
metr=soru81852
print soru8," denizmili"," :",metr," m"
if soru=="b1":
soru9=input(aciklama)
si=soru90.1550
print soru9," cm2"," :",si," inç kare"
if soru=="b2":
soru10=input(aciklama)
my=soru101.1960
print soru10," m2"," :",my," yarda kare"
if soru=="b3":
soru11=input(aciklama)
haa=soru112.4711
print soru11," ha"," :",haa," acre"
if soru=="b4":
soru12=input(aciklama)
kmk=soru120.3861
print soru12," km2"," :",kmk," mil kare"
if soru=="b5":
soru13=input(aciklama)
icm=soru136.4516
print soru13," inç kare"," :",icm," cm2"
if soru=="b6":
soru14=input(aciklama)
acm=soru14929
print soru14," ayak kare"," :",acm," cm2"
if soru=="b7":
soru15=input(aciklama)
yam=soru150.8361
print soru15," yarda kare"," :",yam," m2"
if soru=="b8":
soru16=input(aciklama)
acrem=soru164046.86
print soru16," acre"," :",acrem," m2"
if soru=="b9":
soru17=input(aciklama)
mih=soru17259
print soru17," mil kare"," :",mih," hektar"
if soru=="c1":
soru18=input(aciklama)
gou=soru180.0353
print soru18," gr"," :",gou," ounce"
if soru=="c2":
soru19=input(aciklama)
kgp=soru192.2046
print soru19," kg"," :",kgp," pound"
if soru=="c3":
soru20=input(aciklama)
tkt=soru201.1023
print soru20," ton"," :",tkt," küçük ton"
if soru=="c4":
soru21=input(aciklama)
ongr=soru2128.350
print soru21," onunce"," :",ongr," gr"
if soru=="c5":
soru22=input(aciklama)
pkg=soru220.4536
print soru22," pound"," :",pkg," kg"
if soru=="c6":
soru23=input(aciklama)
ktt=soru230.9072
print soru23," küçük ton"," :",ktt," ton"
if soru=="c7":
soru24=input(aciklama)
btt=soru241.0161
print soru24," büyük ton"," :",btt," ton"
if soru=="d1":
soru25=input(aciklama)
sink=soru250.061
print soru25," cm3"," :",sink," inç küp"
if soru=="d2":
soru26=input(aciklama)
deak=soru260.0353
print soru26," dm3"," :",deak," ayak küp"
if soru=="d3":
soru27=input(aciklama)
myk=soru271.3079
print soru27," m3"," :",myk," yarda küp"
if soru=="d4":
soru28=input(aciklama)
incm=soru2816.390
print soru28," inç küp"," :",incm," cm3"
if soru=="d5":
soru29=input(aciklama)
aydk=soru2928.320
print soru29," ayak küp"," :",aydk," dm3"
if soru=="d6":
soru30=input(aciklama)
yamk=soru300.7646
print soru30," yarda küp"," :",yamk," m3"
if soru=="e1":
soru31=input(aciklama)
liga=soru310.2642
print soru31," litre"," :",liga," galon ABD"
if soru=="e2":
soru32=input(aciklama)
hekbu=soru322.83178
print soru32," hektolitre"," :",hekbu," bushel ABD"
if soru=="e3":
soru33=input(aciklama)
pikl=soru330.5506
print soru33," pint-kuru ABD"," :",pikl," litre"
if soru=="e4":
soru34=input(aciklama)
piyl=soru340.4732
print soru34," pint-yat ABD"," :",piyl," litre"
if soru=="e5":
soru35=input(aciklama)
pntl=soru350.5683
print soru35," pint İngiliz"," :",pntl," litre"
if soru=="e6":
soru36=input(aciklama)
bshl=soru3635.238
print soru36," bushel ABD"," :",bshl," litre"
if soru=="e7":
soru37=input(aciklama)
bshll=soru3736.369
print soru37," bushel İngiliz"," :",bshll," litre"
if soru=="e8":
soru38=input(aciklama)
gall=soru383.7853
print soru38," galon ABD"," :",gall," litre"
if soru=="e9":
soru39=input(aciklama)
gal=soru39*4.5461
print soru39," galon İngiliz"," :",gal," litre"
Comments powered by Disqus