我努力学习LISP和我就要挂了一些基本的东西 -如何反复搜索plist?
我通过列表要循环和查找从列表中值的plist值...
; here it just looks up the plist value
(defun get-plist-value(x) (getf (list :a "1" :b "2") x))
; this is what i want to do, but it doesnt work
; i have tried concatenating the ":" before the x value, but it didnt work either
(loop for x in '(a b) do (get-plist-value x))
; this works
(get-plist-value :a)
谢谢你:-)
我尝试使用格式但是我正在嘲笑〜&。谢谢你的详细解决方案 - 有道理:-) – schmoopy 2011-05-06 16:32:50