TypeError em cálculos com valores de entrada do usuário
Sei que isso foi respondido, mas eu sou um super noob. Eu sei que tem a ver com homem / mulher ser uma string, mas eu pensei que tinha definido? Como posso fazer o cálculo funcionar?
num = int(input('Please enter number of standard drinks consumed:'))
while num <= 0:
print ('Error: The number cannot be negative or zero.')
num = int(input('Please enter number of standard drinks consumed:'))
weight = int(input('Please enter weight in pounds:'))
while weight <= 0:
print ('Error: The weight cannot be negative or zero.')
weight = int(input('Please enter weight in pounds:'))
time = int(input('Please enter number of hours since first drink:'))
while time <= 0:
print ('Error: The time cannot be negative or zero.')
time = int(input('Please enter number of hours since first drink:'))
gender = input('Please enter the sex male or female:')
male = 0.68
female = 0.55
B = -0.015 * time(2.84 * num / weight * gender)
print ('The BAC is', format(B, ',.2f'))