Ken Tilton <kentilton@gmail.com> wrote:
+---------------
| (let ((*print-right-margin* 30)
| (words (split-sequence #\space
| (delete #\newline
| "Four score and seven years ago our fathers brought
| forth on this continent a new nation conceived in liberty and
| dedicated to the proposition that most people like sports bars."))))
| (format t "~2%~2T~{~<~%~2T~10:;~:a~>~^ ~}~3%" words))
|
| ->
| Four score and
| seven years ago
| our fathers
| brought forth on
| this continent a
| new nation
| conceived in
| liberty and
| dedicated to the
| proposition that
| most people like
| sports bars.
+---------------
That one didn't work for me on CMUCL, I got this output instead:
Four score and seven years ago our fathers broughtforth on this
continent a new nation conceived in liberty anddedicated to the
proposition that most people like sports bars.
But when I changed the "~10:;" in the format to "~40:;", I got this:
Four score and seven years ago our
fathers broughtforth on this continent
a new nation conceived in liberty
anddedicated to the proposition that
most people like sports bars.
It looks like CMUCL's ignoring *PRINT-RIGHT-MARGIN* or something...
-Rob
-----
Rob Warnock <rpw3@rpw3.org>
627 26th Avenue <URL:http://rpw3.org/>
San Mateo, CA 94403 (650)572-2607