- 2

Why the output is just 3? Why not 7 as well??

12th Jun 2017, 4:48 AM
Abhishek C. Pathak
Abhishek C. Pathak - avatar
3 Answers
+ 4
# This is about the last quizz of the if-statement Python course :P num = 7 if num > 3: print("3") # you're ok this print 3? if num < 5: # 7 is not < 5, so next code isn't executed, because indented inside this condition ^^ print("5') if num == 7: # the condition is true, but is not run ;) print("7") # so no more this instruction is executed....
12th Jun 2017, 5:10 AM
visph
visph - avatar
+ 3
??
12th Jun 2017, 4:57 AM
Martin Cupak
Martin Cupak - avatar
0
You aren't showing us any code, we can't really help unless we know what's happening.
12th Jun 2017, 5:03 AM
Ajay Gonzalez
Ajay Gonzalez - avatar