Rocksolid Light

News from da outaworlds

mail  files  register  groups  login

Message-ID:  

BOFH excuse #418: Sysadmins busy fighting SPAM.


comp / comp.lang.scheme / Re: Depth First Search traversal of this list

SubjectAuthor
o Re: Depth First Search traversal of this listB. Pym

1
Subject: Re: Depth First Search traversal of this list
From: B. Pym
Newsgroups: comp.lang.lisp, comp.lang.scheme
Organization: A noiseless patient Spider
Date: Fri, 30 Aug 2024 17:31 UTC
Path: eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: Nobody447095@here-nor-there.org (B. Pym)
Newsgroups: comp.lang.lisp,comp.lang.scheme
Subject: Re: Depth First Search traversal of this list
Date: Fri, 30 Aug 2024 17:31:59 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 16
Message-ID: <vasvme$j6b3$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Injection-Date: Fri, 30 Aug 2024 19:32:00 +0200 (CEST)
Injection-Info: dont-email.me; posting-host="7471b6bf57a1160866342d87b5967bc4";
logging-data="629091"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/6oE6Xy3bODoMOyxKjZ03g"
User-Agent: XanaNews/1.18.1.6
Cancel-Lock: sha1:QQfbL9vo3MpNuXpILT9rXG8Aqn0=
View all headers

Kenny wrote:

> (defun tv (x)
> (if (consp x)
> (loop for y in x do (tv y))
> (format t "~a " x)))

Gauche Scheme

(define (tv x)
(if (pair? x) (for-each tv x) (format #t "~a " x)))

(tv '(j k (l m (n o) p) q))

===>
j k l m n o p q

1

rocksolid light 0.9.8
clearnet tor