I am trying to output
Humidity: 42%
using both functions print
and message
. While print
has no problem with the literal percentage sign, message
throws a "Format string ends in middle of format specifier".
What am I missing?
(defun demo()
(interactive)
(progn
(setq text (format "Humidity: %s%%" 42))
(print text)
(message text)
))
(global-set-key (kbd "<f5>") 'demo)
C-h f message