【发布时间】:2016-06-23 08:41:04
【问题描述】:
我在 CLIPS 工作,我有这个 deftemplate:
(deftemplate K-agent (multislot content) (slot free) (slot waste)
一个可能的 K-agent 事实可能是:
(K-agent (content normal normal) (free 0) (waste no))
我想应用这条规则:
?k <- (K-agent (content $?cont) (free ?f))
=> (modify ?k (content (delete-member$ $?cont normal)) (free =(+ ?f 1)))
并获得这个:
(K-agent (content normal) (free 1) (waste no))
但这是我的规则的效果:
(K-agent (content) (free 1) (waste no))
有什么方法可以只删除多槽中的一个相同值?谢谢
【问题讨论】:
标签: clips