Iterative vs. Recursive coding

MRAB python at mrabarnett.plus.com
Fri Aug 20 01:04:26 CEST 2010


Thomas Jollans wrote:
[snip]
> "iterate": use a loop. and again. and again. and again. and again. and aga....
> 
> "recurse": consider. recurse.
> 
> This is another good one: 
> 
> http://mytechquest.com/blog/wp-content/uploads/2010/05/From-a-Programming-Book.jpg
> 
The definition for recursion looks a lot like that for infinite loop.
Perhaps because it's tail-recursive?



More information about the Python-list mailing list