Python has no tail-call optimization, mostly for philosophical reasons. This means thanthat tail-recursing on large structures can cost O(n) memory (because of the unnecessary stack that is kept) and will require you to rewrite the recursion as a loop to get O(1) memory.