From: lawrence.g.mayka
Subject: Re: Adding items to the end of a list.
Date: 
Message-ID: <1990Sep7.005109.27309@cbnewsc.att.com>
In article <····@skye.ed.ac.uk>, ····@aiai.ed.ac.uk (Jeff Dalton) writes:
> In article <····················@mentor.com> ······@mentor.com (Patrick Logan) writes:
> >I see a lot of LISP code building lists backwards and then reversing
> >them. I don't know if I've ever seen any C code doing that. Is it too
> >easy to write sloppy code in LISP? I don't think it is any more
> >difficult to write efficient list manipulations in Scheme than it is
> >in C.
> 
> How soon they forget.  What do you think `tconc' (Interlisp,
> Franz Lisp, etc.) was for?
> 
> For a more modern approach, look at Appendix B, "Generators and
> Gatherers" in Guy Steele Jr.'s CLtL II.  (It's similar to your
> object-oriented technique.)

The "Series" of Appendix A are often useful here too, as well as old
standbys like MAPCAR.  Otherwise, I use the COLLECT keyword of the new
expanded LOOP macro.


	Lawrence G. Mayka
	AT&T Bell Laboratories
	···@iexist.att.com

Standard disclaimer.