Last active
November 12, 2016 11:10
-
-
Save mtimkovich/0954e5c15fc117e4f54dd3ab6cde7019 to your computer and use it in GitHub Desktop.
You already know
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(use format) | |
(define (beer-song n) | |
(format #t "~A bottle~:P of beer on the wall.~%" n) | |
(format #t "~A bottle~:P of beer.~%" n) | |
(print "Take one down.") | |
(print "Pass it around.") | |
(let ((n (- n 1))) | |
(if (> n 0) | |
(begin | |
(format #t "~A bottle~:P of beer on the wall.~%" n) | |
(beer-song n)) | |
(print "No more bottles of beer on the wall.")))) | |
(beer-song 99) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment