Conditions and control flow of if elif,else with and or not


#1

def the_flying_circus():
if (10 <20) and not(10 != 20):
return "True"
elif (10+20 >=20-10):
return "True"
else:
return "Fasle"
a = the_flying_circus()
print a

The output came as True. However, below message came in the below the editor window after the code executed

Oops, try again. the_flying_circus() should return True, instead it returned: 'True'
I could not understand where I have done mistake. I request folks to help me out
thanks
sam


#2

The function should return the boolean values True or False, not the strings "True" or "False".


#3

Here's how I passed

def the_flying_circus():
    if 10 > 0 and 10 != 0:    
        return True
    elif 10 < 0 or not 10 <= 10:
        return "Quite True"
    else:
        return "Completely False"

#4

Thanks for the help. I corrected it and it worked


#5

Good looks, this helped me figure out the #%#^& a return statement was cause' thats was what got me stuck