Lisp Implementation (cont.)
(defun really-search (frontier
goal-checker
state-generator
rank-function)
(cond
((null frontier) NIL)
(T (let ((next-state (car frontier)))
(cond
((funcall goal-checker next-state)
next-state)
(T (let ((new-states (funcall state-generator
next-state)))
(really-search
(sort-states
(append new-states (cdr frontier))
rank-function)
goal-checker
state-generator
rank-function))))))))
Previous slide
Next slide
Back to first slide
View graphic version