请问,我的代码有什么不好的?我该如何修改?
(define pivot (lambda (l)
(cond ((null? l) 'done)
((null? (cdr l)) 'done)
((<= (car l) (cadr l)) (pivot (cdr l)))
(#t (car l)))))
(define (quicksort l)
(let ((piv (pivot l)))
(if (equal? piv 'done) l
(let ((parts (partition piv l () ())))
(append (quicksort (car parts))
(quicksort (cadr parts)))))))