Last active
December 22, 2015 08:38
-
-
Save fukamachi/6446193 to your computer and use it in GitHub Desktop.
Print "Hello World" to the *standard-output* without using integer, string and character literals in Common Lisp.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; This is a answer for a question of CodeIQ. | |
;; https://codeiq.jp/ace/cielavenir/q431 | |
(in-package :cl-user) | |
(defmacro print-capitalized (symbol &rest symbols) | |
`(progn | |
(princ ,(string-capitalize symbol)) | |
,@(loop for s in symbols | |
collect `(princ ,(name-char 'space)) | |
collect `(princ ,(string-capitalize s))))) | |
(print-capitalized hello world) | |
;-> Hello World |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment