Iteration over recursion?
bdesth.quelquechose at free.quelquepart.fr
Wed Jun 21 00:30:10 CEST 2006
Sudden Disruption a écrit :
>>It doesn't. Technical possible, but BDFL's decision...
> Sure. But why bother?
Because I do like recursion, and would personnally prefer tail-recursion
optimisation over nice tracebacks. But I'm not in position to decide
> Anything that can be done with recursion can be done with iteration.
> Turng proved that in 1936.
Yes. And everything done with Python can be done with assembly language
> Recursion was just an attempt to "unify" design approach by abstracting
> itteration and creating a new context. It allowed the programmer to
> isolate himself from the reality that he was actually iterating. Talk
> about mind fuck.
Recursion is the most convenient way to express some common algorithms.
Too bad for you if it does some nasty things to your mind.
More information about the Python-list