Skip to content

Instantly share code, notes, and snippets.

@samth

samth/arc-if.rkt

Created Oct 12, 2012
Embed
What would you like to do?
#lang racket
(require syntax/parse/define)
(define-simple-macro (if (~seq test result) ... final)
(cond [test result] ... [else final]))
(if (even? 7) "seven" (odd? 8) "eight" "neither")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment