RosettaCodeData/Task/Copy-stdin-to-stdout/Common-Lisp/copy-stdin-to-stdout.lisp

6 lines
264 B
Common Lisp
Raw Permalink Normal View History

2023-07-01 11:58:00 -04:00
#|Loops while reading and collecting characters from STDIN until EOF (C-Z or C-D)
Then concatenates the characters into a string|#
(format t
(concatenate 'string
(loop for x = (read-char *query-io*) until (or (char= x #\Sub) (char= x #\Eot)) collecting x)))