format with two lists

Discussion of Common Lisp
Post Reply
stackman
Posts: 28
Joined: Sat Oct 06, 2012 5:44 am

format with two lists

Post by 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.

wvxvw
Posts: 127
Joined: Sat Mar 26, 2011 6:23 am

Re: format with two lists

Post by 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.

Post Reply