我的方案的功能正在試圖獲得全省細節:方案:爲什麼我收到此錯誤-assertion違章:錯誤類型[汽車]的參數(車「())
(define (getProvincesHelper sales provincesList)
(if (null? sales)
provincesList
(getProvincesHelper (cdr sales) (append (list (cadr(cadddr sales))) provincesList))
)
)
(define (getProvinces sales)
(getProvincesHelper sales '())
)
名單的數據是這種格式
;(orderNum (orderDate shipDate) (grossSale discount profit unitPrice) (deliveryMethod province) product)
(3 ("10/13/2010" "10/20/2010") (261.54 0.04 -213.25 38.94) ("Regular Air" "Nunavut") "Eldon Base for stackable storage shelf, platinum")
我得到的錯誤:
assertion-violation: argument of wrong type [car]
(car '())