Binary

From mojo_puzzler
Revision as of 15:51, 17 November 2023 by Gneale (talk | contribs) (Created page with "===== Return to: Chialisp ===== ===== Return to: Recursive Functions ===== <pre> (defun binary (n) (if (= n 1) (* n 2) (* 2 (binary (- n 1))))) </pre>")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
Return to: Chialisp
Return to: Recursive Functions
(defun binary (n)
  (if (= n 1)
      (* n 2) 
      (* 2 (binary (- n 1)))))