(defclass Man (is-a USER)
(object (is-a Man) (friends ?f))
(printout t "We have a friend." crlf))
(make-instance jack of Man (friends create$ pete)) matches
(make-instance jack of Man (friends create$ pete sue)) does NOT match
What am I doing wrong?
Your pattern matches a Man having exactly one friend. You want to use either (friends ?f $?) or (friends ? $?) and your make-instance call can be simplified to (make-instance jack of Man (friends pete sue)).
Thanks Gary I really appreciate how you take time to answer questions. I think clips is fantastic.
Log in to post a comment.
Sign up for the SourceForge newsletter:
You seem to have CSS turned off.
Please don't fill out this field.