My bmi calculator is running backwards

تعرفه تبلیغات در سایت

آخرین مطالب

امکانات وب

Vote count: 0

My Bmi calculator that I am writing for school is producing my output backwards, it first calls for user information and than for name information. Please help, i need it to be the other way around.

user = str
end = False


def bmi_intro():
print("BMI Calculator")
while end == False:


    user = input("Enter students name or '0' to quit: ")
    if user == "0":
        print("end of report!")
    else:
        def userName(str):
            user = str
        print("Lets gather your information,", user)
        break

get_height = float(input("Please enter your height in inches: "))
get_weight = float(input("Please enter your weight: "))
body_mass_index = (get_weight * 703) / (get_height ** 2)
print ("Your bmi is: ", body_mass_index)

def main():
  get_height = 0.0
  get_weight = 0.0
  body_mass_index = 0.0
bmi_intro()
asked 1 min ago
Docrunner

نویسنده : استخدام کار بازدید : 10 تاريخ : دوشنبه 21 خرداد 1397 ساعت: 0:00

فهرست وبلاگ