From ... From: Erik Naggum Subject: Re: Help Date: 1998/03/20 Message-ID: <3099401333254064@naggum.no>#1/1 X-Deja-AN: 335982592 References: <350DE565.732@ibm.net> mail-copies-to: never Organization: Naggum Software; +47 8800 8879; http://www.naggum.no Newsgroups: comp.lang.lisp * temp | Hi I am trying to write an iterative lisp function that given a list A | returns a list with everything in A repeated twice consecutively. For | example A = [a,b,c] then the newlist = [a,a,b,b,c,c]. Any help would be | greatly appreciated. Thanks. first, you have a pretty weird syntax for lists, but I guess you still mean lists like (A B C) and (A A B B C C) not something else entirely. however, back to your homework assignment: as you may have found out, there are many ways to do what you want to do, but I have not yet seen the simple _iterative_ solutions: (loop for e in collect e collect e) I'm sure you are not allowed to use LOOP, but rewriting this to use DO or DOLIST shouldn't be too hard. #:Erik -- religious cult update in light of new scientific discoveries: "when we cannot go to the comet, the comet must come to us."