[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

question about format



>>>>> "Dan" == Dan Stanger <dxs@evolving.com> writes:

Dan> i want to use format to concatonate 3 strings in a fixed length
Dan> field.  for example: 

Dan> (format nil "~16a" (format nil "~A~A~A" "123" "456" "123"))
Dan> "123456123 "

Dan> however in the above example i
Dan> need to do 2 formats, one to concatenate the strings, the other
Dan> to put it into a fixed length field.  is is possible to do this
Dan> with one format call? 

Here is one way:

(format nil "~16@<~@{~A~}~>" "123" "456" "123")