Karsten Johansson<p>Lisp sucks. Tell me what's wrong here:</p> <p>(DEFVAR x 0) ; GLOBAL BADNESS STAYS</p><p>(DEFUN dO-StuFf (NUMBer)<br> (LET ((rEsUlT 1))<br> (DECLARE (SPECIAL X)) ; THIS IS LEGAL HERE<br> (SETQ X NUMBER)<br> (TAGBODY<br> StaRT<br> (IF (< X 1) (GO ENDz))<br> (SETQ rEsUlT (* rEsUlT X))<br> (SETQ x (- x 1)) ; NOTE: STILL USING GLOBAL <code>x</code> INSTEAD OF LOCAL <code>X</code><br> (GO StARt)<br> ENDz)<br> (pRiNt (lIsT 'FACtoRiAl-oF NUMBER 'iS rEsUlT))))</p><p>(DEFUN nOW-dO-AlL ()<br> (LET ((I 0))<br> (LOOP<br> (WHEN (> i 5) (RETURN))<br> (Do-sTUFF i)<br> (SETQ i (+ i 1)))))</p><p><strong>(nOW-dO-AlL)</strong></p><p><a href="https://infosec.exchange/tags/commonlisp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>commonlisp</span></a> <a href="https://infosec.exchange/tags/lisp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>lisp</span></a> <a href="https://infosec.exchange/tags/sbcl" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>sbcl</span></a> <a href="https://infosec.exchange/tags/clisp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>clisp</span></a> <span class="h-card" translate="no"><a href="https://mastodon.social/@amszmidt" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>amszmidt</span></a></span> <span class="h-card" translate="no"><a href="https://mastodon.sdf.org/@screwtape" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>screwtape</span></a></span></p>