[Tutor] Unsupported operand types for +: 'NoneType' and 'int' - HUH?!

Eladio Ventura eladioventura@yahoo.com
Fri Jun 6 17:11:24 2003


* Neil Schemenauer <nas@python.ca> [030603 16:16]:
> Your problem is with the line "if tree == None: return".  You want:
> 
>     if tree is None:
>         return 0
> 
> Note that a bare return statement is the same as "return None".
AAAAAAARRRRGGGHHH!!! 45 MINUTES wasted on something *this* simple?! Oh
well, one step closer to coder-dom, ha ha! Thanks a lot, it works like a
charm! This list is the best!
-- 
"Thinking gives you wrinkles!"
Malibu Stacy, the Simpsons