On Fri, Aug 30, 2013 at 01:37:39AM +0200, bearophile wrote:
> H. S. Teoh:
> 
> >Also, this is a pretty poor algorithm for generating the Fibonacci
> >series,
> 
> I know, but you must do what the tasks asks you:
> 
> http://rosettacode.org/wiki/Anonymous_recursion
[...]

OK I see.

I wish we could reeducate people that recursive Fibonacci algorithms are
Bad(tm). :) There are better examples of recursion that don't have poor
performance characteristics, or where no better alternative exists. Like
parsing expression trees, for example (even though the parser can be
recursive, it is only linear in the size of the input, so it's not bad).


T

-- 
I think the conspiracy theorists are out to get us...

Reply via email to