Re: Page 3 and 19, value of (+ 3 (* 24))

19 views
Skip to first unread message
Message has been deleted

Marcus Denison

unread,
Feb 7, 2012, 1:02:59 PM2/7/12
to land-o...@googlegroups.com
Dear Alexander,

(+ 3 (* 2 4)) is evaluated from inside to the outside. So first there
will be 2 * 4, which is 8 and then 3 is added.

Maybe you have a typo? (+ 3 (* 24)) <- There is a whitespace missing.

I haven't done some LISP in a very long time, but that should be the
trick. Hopefully I was helpful.

Greetings

Am 07.02.12 18:58, schrieb Alexander Kruel:
> The value of (+ 3 (* 24)) seems to be 27 rather than 11? 3+24*1
>
> I just started reading the book and do have almost no previous
> programming experience. Maybe I am missing something really obvious
> here. But when I use GNU CLISP 2.49 to evaluate the expression it
> returns 27.

Reply all
Reply to author
Forward
Message has been deleted
0 new messages