-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathkilo_boy_index.py
More file actions
23 lines (19 loc) · 882 Bytes
/
kilo_boy_index.py
File metadata and controls
23 lines (19 loc) · 882 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
print("\nKİLO-BOY İNDEXİ\n")
name = input("Ad: ")
kg = float(input("Kilo: "))
hg = float(input("Boy: "))
index = (kg) / (hg ** 2)
zayif = (index >= 0) and (index <= 18.4)
normal = (index > 18.4) and (index <= 24.9)
kilolu = (index > 24.9) and (index <= 29.9)
obez = (index >= 29.9) and (index <= 34.9)
if (index >= 0) and (index <= 18.4):
print(f" {name} kilo indeksin: {index} ve kilo değerlendirmen zayıf: {zayif}")
elif (index > 18.4) and (index <= 24.9):
print(f" {name} kilo indeksin: {index} ve kilo değerlendirmen normal: {normal}")
elif (index > 24.9) and (index <= 29.9):
print(f" {name} kilo indeksin: {index} ve kilo değerlendirmen kilolu: {kilolu}")
elif (index >= 29.9) and (index <= 34.9):
print(f" {name} kilo indeksin: {index} ve kilo değerlendirmen obez: {obez}")
else:
print("Hatalı giriş yaptınız. Lütfen tekrar deneyiniz...")