Nevwild / SICP

My journey through the SICP
0 stars 0 forks source link

Question on Exercise 1.3 #2

Open Nevwild opened 7 years ago

Nevwild commented 7 years ago

In my answer favorite answer to exercise 1.3 I found that I needed to call (min x y) twice in a line to evaluate more than 2 parameters. I don't like the idea that I need to call a function like min over and over again if I have more than 2 values to compare. In the solution I made a comment about my how I'm assuming this is handled.

Could you take a look at the code at the following link and let me know if I'm headed down the right path?

https://github.com/Nevwild/SICP/blob/29977ef207006652aebc43b5c26457d0cace4624/SICP%201.3.lisp#L18

apvd commented 7 years ago

(define (min . args-list) ...)