The Big If


#1

I don't understand exactly what I should be doing here

Error Messages

  File "python", line 6
    elif ________:
       ^
IndentationError: expected an indented block
 



Oops, try again.
An exception was raised while running your code, see the console window for the error message.




# Make sure that the_flying_circus() returns True
def the_flying_circus(I love the circus):
    if I love the :    # Start coding here!
        # Don't forget to indent
        # the code inside this block!
    elif ________:
        # Keep going here.
        # You'll want to add the else statement, too!
    else:
        print


#2

Start by reading the instructions very carefully. You have lots of options, but must follow the instructions.


#3

I did but I'm confused by the def function in the code editor


Make sure that the_flying_circus() returns True

def the_flying_circus(I love the circus):
if the_flying_circus(): # Start coding here!
print "This is great: # Don't forget to indent
# the code inside this block!
elif ________:
# Keep going here.
# You'll want to add the else statement, too!
else:
print "All work is in vain"


#4

Did you read the part that says the function takes no parameters, and must return True?

The above line contains several errors, four in fact. I love the circus. Remove all of that and you are well underway.

def the_flying_circus():

#5

I'm stuck too! It keeps saying my error is "make sure that the_flying_circus() returns True", but i forgot how to do that part :frowning:


#6

When you see something like this in a code template,

if ____:

elif ____:

else:

It means we have to fill in the blanks with a valid expression for each. But, it at least gives us the blocked out syntax to work from. The rest is pretty straight forward, given all the structure.

This exercise wants us to write comparison expressions that use our choice of operators, so long as we change up our use:

Write an if statement in the_flying_circus(). It must include:

if, elif, and else statements;
At least one of and, or, or not;
A comparator (==, !=, <, <=, >, or >=);

Finally, the_flying_circus() must return True when evaluated.

There is no criteria beyond that. We can pick anything we like to compare,

Have you got a handle on what an expression is? A Comparison? Logical operators? On if statements? If not, then go back to the start of the module and cover all the material again.

This is the last exercise of a module that covers everything that is expected here. It's like a review. It is not a problem, but a chance to explore what you have learned. Getting help at this stage is asking for a lot, when you really need to help yourself with this one.


#7

I forgot what to do at this part as well, As a result I'm stuck.


#9