From: yoav gonen
Subject: How to do set! on lists?
Date:
Message-ID: <hobbit.660999284@shum>
I've already tried to do set! on lists and it did'n't worked out.
I assume that I must use set-car! or set-cdr! in order to change a list,
but if,for example i want to change a given list to a null one ( == '() )
how can I do that???
In article <·····················@Think.COM>, ······@think.com (Barry Margolin)
writes:
|> In article <················@shum> ······@huji.ac.il (yoav gonen) writes:
|> >I've already tried to do set! on lists and it did'n't worked out.
|> >I assume that I must use set-car! or set-cdr! in order to change a list,
|> >but if,for example i want to change a given list to a null one ( == '() )
|> >how can I do that???
|>
|> [...nice explanation of basic lisp data structures...]
|>
|> I hope this explanation helps, but I'm somewhat doubtful (no offense
|> intended). The original question suggests a major lack of understanding of
|> Lisp data structures, and the above may confuse more than it helps. I urge
|> you to seek out a local Lisp/Scheme programmer, or a good Lisp text
|> (unfortunately, few of the texts use Scheme, so you'll have to deal with
|> syntactic differences), and get enlightened.
Well done. This is the only news group I know in which a novice would
be treated so gently.
My response might have been something like 'buy a clue, buddy'!
Must be working with C/C++ weenies too much...