Skip to content

Instantly share code, notes, and snippets.

@tasuten
Last active January 1, 2016 20:49
Show Gist options
  • Save tasuten/8199074 to your computer and use it in GitHub Desktop.
Save tasuten/8199074 to your computer and use it in GitHub Desktop.
書き初め@2014
#!/usr/local/bin/gosh
(define (main args)
(print (map fizzbuzz (iota 2014 1)))
0 )
(define (dividable x y)
(zero? (mod x y)))
(define (fizzbuzz x)
(cond
((dividable x 15) "fizzbuzz")
((dividable x 5) "buzz")
((dividable x 3) "fizz")
(else x)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment