NextPrevUpTopContentsIndex

any

Function
Syntax

any pattern-to-instantiate goal-to-prove

Arguments

pattern-to-instantiate is a list or symbol. goal-to-prove is any backward chaining goal.

Description

The backward chaining inference engine is started to look for any set of bindings which satisfy goal-to-prove . Using those bindings, pattern-to-instantiate is instantiated and returned.

Values

Two values are returned. The second value indicates with T that a proof was found, or with nil that no proof exists. In the former case, the first value is the instantiated version of pattern-to-instantiate , in the latter case, the first value is nil .

Examples
(any '(?x is in (1 2 3)) '(member ?x (1 2 3)))

returns (1 is in (1 2 3))

(any '(?truck is a truck) '(truck ?truck))

returns (#<TRUCK TRUCK5> IS A TRUCK)

See also

findall


KnowledgeWorks and Prolog User Guide (Unix version) - 4 Apr 2005

NextPrevUpTopContentsIndex