0
我想下面的代碼合併到一個:如何結合這兩個功能(方案)?
(define (foundList x)
(when (pair? x)
((hash-ref *function-table* (car x)) (cdr x))))
(define (endofstring x)
(if (not (null?(cdr x)))
(endofstring (cdr x))
(foundList (car x))))
我試着做以下,但我得到「哈希REF:沒有發現鍵值」
(define (endofstring x)
(if (not (null?(cdr x)))
(endofstring (cdr x))
(if (when (pair? x)
((hash-ref *function-table* (car x)) (cdr x)))
(car x) (void))))
需要幫助感謝名單
它沒有工作...我得到以下結果......「時:語法錯誤 在:(時(對?(car x)((hash-ref * fun-table *(car(car x)))(cdr(car x)))))「 – mike123
@ mike123壞括號。現在修復。 – molbdnilo