+ 3
New to Python - Small problem.
Hi All! I just started learning Python yesterday and below is a link to a small script for temperatures that I just started... https://code.sololearn.com/c67zSh4yc9IS/#py My problem is that is there a code/action that I can add to the script so that after I input temp = 50 the "print ("\nToday is a NICE day!")" won't appear? Thank you very much in advance for your help!
1 Resposta
+ 4
You should probably use multiple elifs there:
if x > 10:
pass
elif x < 10 and x > 7:
pass
elif x < 7 and x > 5:
pass
else:
pass