¨

10.1.2 Data Structures

Another feature of Prolog is its ability to allow the dynamic assertion and retraction of rules and facts. This makes the Prolog rule and data base truly dynamic at run-time. This is essential for “learning systems” and other applications involving the introduction of new concepts, rules or facts at run-time.

Memory is dynamically allocated and deallocated at run-time. The deallocation is automatically done by a built-in garbage collector. The programmer does not have to be concerned with the implementation, maintenance and bookkeeping normally associated with the creation and destruction of complex dynamic data structures and is freed to concentrate on stating the logic of the problem.og programs consist of facts and rules, which are referred to as clauses. A fact consists