Maximum Recursion Depth Exceeded Runtime Error - Help please!


#1



Link to Python excerise I am struggling with:
https://www.codecademy.com/courses/python-beginner-BxUFN/4/1?curriculum_id=4f89dab3d788890003000096#

My code is below, and generates the following error message... Not sure what I am missing....

"Oops, try again. The following exception was raised when calling the_flying_circus(): RuntimeError: maximum recursion depth exceeded"




def the_flying_circus():
if the_flying_circus():
return True
elif the_flying_circus():
the_flying_circus() != the_flying_circus1 and (2 < 1)
return False
else:
print "none of the above"

PS post here is eating my indentations for if, elif, else, and items under them


#2

You are calling the function inside of it's own definition.


#3

lol thanks! I just solved it looking at someone else's unrelated question. Thanks so much for your speedy reply! It is very encouraging!!!!


#4

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