Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 2

Date: 9/20/2012

Ravikumar Mav
CWID: 892127077
Home Work-3 (CPSC 583)
CLIPS> (assert(member-of beatles john_lennon paul_mccartney george_harrison
ringo_starr)
(member-of who roger_daltrey pete_townsend keith_moon)
(member-of ebtg tracey_thorn ben_watt)
)
<Fact-3>
=>using multi field wild card.
CLIPS> (defrule band-members
(member-of ?band $?members)
=>
(printout t "the members of " ?band " are " $?members crlf)
)
=>output
CLIPS> (run)
the members of ebtg are (tracey_thorn ben_watt)
the members of who are (roger_daltrey pete_townsend keith_moon)
the members of beatles are (john_lennon paul_mccartney george_harrison
ringo_starr)

Date: 9/20/2012
=>using multi field wild card.
CLIPS> (defrule band-members
(member-of ?band $? ?members $?)
=>
(printout t "the members of " ?band " is " ?members crlf)
)
=>output
CLIPS> (run)
the members of ebtg is tracey_thorn
the members of ebtg is ben_watt
the members of who is roger_daltrey
the members of who is pete_townsend
the members of who is keith_moon
the members of beatles is john_lennon
the members of beatles is paul_mccartney
the members of beatles is george_harrison
the members of beatles is ringo_starr

You might also like