COND
Think of COND as if/elseif/elseif/elseif/endif
Each clause has a test followed by what to do if that test is true.
(cond ((= x 1)
(print 'single))
((= x 2)
(print 'twin)
(print "You WIN"))
((= x 3)
(print 'triplet))
(t
(print 'unknown)
(print "Too Bad")
x))
Previous slide
Next slide
Back to first slide
View graphic version