begin quoting Christopher Smith as of Fri, Jan 25, 2008 at 10:34:41AM -0800: > [EMAIL PROTECTED] wrote: > > I used to think recursion was just a cute idea but from learning Scheme > > it appears that recursion is somehow vital to this whole language. > > > > Anyone know what is so special about recursion besides the fact that > > it allows you to write shorter code? > > Recursion doesn't require mutating variables, which allows you to do > iteration without mutating variables. Once you have ways of doing things > without mutating state, you discover a whole world of possibilities, not > the least of which is fewer bugs, implicit parallelism, easily provable > outcomes, etc..
Yah, the junior programmer using recursion can't get the code to run, which is one bug, rather than using a procedural language that runs, but dies in a wide variety of ways, resulting in lots of bug (reports). ;-P And when it comes to code, there's nothing "easily provable". That's just mathematician-speak for "I told me thesis student to do it." -- I can't seem to buy these non-mutating-state-solves-my-problem memes; Nothing comes for free, and what claims otherwise isn't what it seems. Stewart Stremler -- [email protected] http://www.kernel-panic.org/cgi-bin/mailman/listinfo/kplug-lpsg
