Discuss / Python / Test results

Test results

Topic source

Cyslyinmo

#1 Created at ... [Delete] [Delete and Lock User]
height=1.75weight=80.5bmi=weight/(height**height)if bmi <18.5:    print(f'{bmi:.1f},过轻')elif bmi >= 18.5 and bmi <25:    print(f'{bmi:.1f},正常')elif bmi >= 25 and bmi <28:    print(f'{bmi:.1f},过重')elif bmi >= 28 and bmi <32:    print(f'{bmi:.1f},肥胖')else:    print(f'{bmi:.1f},严重肥胖')

Cyslyinmo

#2 Created at ... [Delete] [Delete and Lock User]
height=1.75weight=80.5bmi=weight/(height**height)if bmi <18.5:    print(f'{bmi:.1f},过轻')elif bmi >= 18.5 and bmi <25:    print(f'{bmi:.1f},正常')elif bmi >= 25 and bmi <28:    print(f'{bmi:.1f},过重')elif bmi >= 28 and bmi <32:    print(f'{bmi:.1f},肥胖')else:    print(f'{bmi:.1f},严重肥胖')

  • 1

Reply