[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: perhaps I've missed something ...

sperber@xxxxxxxxxxxxxxxxxxxxxxxxxxx (Michael Sperber [Mr. Preprocessor]) writes:

> me> 1. what I, in my naivete about PL design, take "set!" to be?
> me> (set! <name> <value>) translates, in my mind, to: dear Scheme, please
> me> make it so that next time I say <name>, and <name> denotes the same
> me> thing as now, I get <value>.
> But this intuition is wrong

I think you missed the now-underlined part.

> , because SET! has interaction with *place*
> (in the program source code) in addition to interaction with time.
> (define x 23)
> (let ((x 5))
>   (set! x 17))
> x => 23
> This is precisely the case students struggle with.

I really begin to wonder about your students...

> Cheers =8-} Mike


Tools that are no good require more skill.