format with two lists

Discussion of Common Lisp

format with two lists

Postby stackman » Fri Nov 09, 2012 9:34 am

hi,
is there a format directive that loops over two lists, as follows?
Code: Select all
(format "..." (list 1 2 3) (list 'a 'b 'c ))
=> 1 'a
   2 'b
   3 'c

I know that I can map format on the two lists. My goal here
is to understand the format directives a bit better.
stackman
 
Posts: 28
Joined: Sat Oct 06, 2012 5:44 am

Re: format with two lists

Postby wvxvw » Fri Nov 09, 2012 11:08 am

I don't think so... except for ~[...~] block nothing can process more then a single argument at a time, not even your custom function you could've plugged into format with ~/your-function/.
I'm not 100% sure, but it's close.
wvxvw
 
Posts: 126
Joined: Sat Mar 26, 2011 6:23 am


Return to Common Lisp

Who is online

Users browsing this forum: No registered users and 2 guests

cron