Name: Anonymous 2011-12-07 13:05
Give me three good reasons to use Lisp or Scheme instead of C++
(define x 2)
(define y 3)
(define a 0)
(eval ((λ (anus)
(define (hax t)
(match t
[(regexp #rx"^(.+) *\\+ *(.+)$" `(,_ ,op1 ,op2)) `(+ ,(hax op1) ,(hax op2))]
[(regexp #rx"^(.+) *\\* *(.+)$" `(,_ ,op1 ,op2)) `(* ,(hax op1) ,(hax op2))]
[(regexp #rx"^([0-9.]+) *$" `(,_ ,num)) (string->number num)]
[(regexp #rx"^([A-Za-z0-9.]+) *$" `(,_ ,lit)) (string->symbol lit)]))
(match anus
[(regexp #rx"^([a-zA-Z0-9]+) *= *(.+)$" `(,_ ,lhs ,rhs))
`(set! ,(string->symbol lhs) ,(hax rhs))])
) "a = x+10*y"))
a
32