chickadee » aima » make-reflex-agent

make-reflex-agent locationprocedure
make-reflex-agent location programprocedure

Make a stateless agent that merely responds to its current percept.

location
Where does the agent start? `left' or `right'
program
The agent's program; should be a binary procedure that takes a location and whether that location is clean. See `simple-agent-program'.
(define make-reflex-agent
  (case-lambda
    ((location) (make-reflex-agent location (default-agent-program)))
    ((location program) (make-agent location 0 program))))