DrRacket

1 (define tst
2   (lambda (l)
3     (cond
4       (null? l))))

> (tst '())
()

1 (define tst
2   (lambda (l)
3     (cond
4       ((null? l)))))

> (tst '())
#t

1 (define tst
2   (lambda (l)
3     (cond
4       ((null? l) #t)
5       (else #f))))

> (tst '())
#t
> (tst '(a))
#f

posted @ 2013-01-20 09:58  NiJc  阅读(222)  评论(0编辑  收藏  举报