(define pick
(lambda (num lat)
(cond ((null? lat) (quote()))
((= (sub1 num) 0) (car lat))
(else
(pick (sub1 num) (cdr lat))))))
(define brees (quote (a b c d e touchdown g h i)))
(pick 6 brees)
DrRacket 中的语言设置为高级学生。在定义sub1
.
错误信息是:
reference to undefined identifier: R