Stuck!


#1

a= raw_input("input a number") 
def the_flying_circus():   
    if a<3 and a>0:
        return True
    elif a>=3:
        return False
    else:
        return False


https://www.codecademy.com/courses/python-beginner-BxUFN/4/1?curriculum_id=4f89dab3d788890003000096#


when i enter 2 it keeps saying that the_flying_circus() was returned False


Replace this line with your code.


#2

raw_input doesn't store the result as a integer, which means the comparison done isn't good, try casting a to a integer:

a= int(raw_input("input a number") )

#3

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.