(define (deep-reverse l) (define (iter a r) (cond ((null? a) r) ((list? (car a)) (iter (cdr a) (cons (deep-reverse (car a)) r))) (else (iter (cdr a) (cons (car a) r))))) (iter l '()))
No comments:
Post a Comment