Skip to content

Instantly share code, notes, and snippets.

@7h3kk1d
Created December 11, 2012 13:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save 7h3kk1d/4258615 to your computer and use it in GitHub Desktop.
Save 7h3kk1d/4258615 to your computer and use it in GitHub Desktop.
FizzBuzz Test in MIT/GNU Scheme
(define n 0)
(do ()
((= n 101))
(cond
((eq? (modulo n 15) 0) (display "FizzBuzz\n"))
((eq? (modulo n 3) 0) (display "Fizz\n"))
((eq? (modulo n 5) 0) (display "Buzz\n"))
(else (map display (list n "\n")))
)
(set! n (+ n 1))
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment