;deftemplates (deftemplate trip (slot payment) (slot interest) (slot destination)) ;defrules (defrule Huntington-Beach (trip (payment cash) (interest sun)) => (assert (trip (destination Huntington))) (printout t " You are going to Huntington beach" crlf)) (defrule Hawaii-Beach (trip (payment check) (interest sun)) => (assert (trip (destination Hawaii))) (printout t " You are going to Hawaii" crlf)) (defrule Hawaii-Beach2 (trip (payment charge) (interest sun)) => (assert (trip (destination Hawaii))) (printout t " You are going to Hawaii" crlf)) (defrule Aspen-Mtn (trip (payment cash) (interest snow)) => (assert (trip (destination Aspen))) (printout t " You are going to Aspen" crlf)) (defrule Aspen-Mtn2 (trip (payment check) (interest snow)) => (assert (trip (destination Aspen))) (printout t " You are going to Aspen" crlf)) (defrule Alpes-Mtn (trip (payment charge) (interest snow)) => (assert (trip (destination Alpes))) (printout t " You are going to the Swiss Alpes" crlf)) ;(defrule get-payment ; => ; ;(printout t "What is your payment method? " crlf) ; (printout t "cash check or charge? ") ; (bind ?response (read)) ; (assert (trip (payment ?response)))) ;(defrule get-interest ; => ; (printout t "What is your interest? " crlf) ; (printout t "sun or snow ") ; (bind ?response (read)) ; (assert (trip (interest ?response)))) ;(deffacts my-trip ; (trip(payment cash)(interest sun)))