The Big If


#1



This is my code:

 # Make sure that the_flying_circus() returns True
def the_flying_circus():
    if True and not True:    # Start coding here!
        print True
        # the code inside this block!
    elif 6 == 6:
        print True
        # Keep going here.
    else:
        print False
print the_flying_circus()

This is the error message:
Oops, try again. the_flying_circus() returned the value None, did you forget to add a return statement?

This is what is being returned:
True
None
None

Any idea what I'm doing wrong and how to fix it?


#2

Hi try to change the print statements with return statements


#3

def the_flying_circus():
if True and not True: # Start coding here!
return True
# the code inside this block!
elif 6 == 6:
return True
# Keep going here.
else:
return False
print the_flying_circus()

This should work i think i have fixed it for you.


#4

@wizmarco and @awesomealphabet Thanks, that worked!:slight_smile:


#5

Your Welcome. Happy to help :smile:


#6

thanks - i just couldn't get past the directions - i saw way too many possibilities which is a bad thing - i redid the code totally probably 10 times before i read your post - changed it one last time and it's all good