Section 1.1 Exercises (Responses Have Answers)
Brad Beyenhof
bbeyenhof at gmail.com
Fri Jan 25 15:58:51 PST 2008
On Jan 25, 2008 3:53 PM, Mark Schoonover <mark.schoonover at gmail.com> wrote:
> On Jan 23, 2008 11:28 PM, Brad Beyenhof <bbeyenhof at gmail.com> wrote:
> > Ex. 1.6
> >
> > 'new-if' uses cond to spawn a sub-environment (or "child process,"
> > maybe?) for each recursion of sqrt-iter, and it never comes back out
> > to deliver a value to the function. On the other hand, the special
> > form 'if' stays at the top level of the definition and can return a
> > value to the function.
>
> That's not the way I'm thinking new-if works. The built-in if will eval
> one predicate at a time, where as new-if will try to do both at the same
> time and get into a loop.
Aha... that actually makes much more sense (plus, it's more related to
the concepts currently presented in the text). I think you win. :)
--
Brad Beyenhof http://augmentedfourth.com
The history of popular music is littered with great partnerships.
Rodgers had his Hammerstein, Lennon had his McCartney, and Lloyd Webber
had... his photocopier... ~Humphrey Lyttleton
More information about the KPLUG-LPSG
mailing list