__About Prolog and Logic Programming__

Logic programming is a declarative programming paradigm, in which the programmer

specifies the properties of a correct answer (for example, by using rules); depending

on these properties, a certain computation is carried out by the underlying engine for

obtaining the solution.

Logic programming languages commonly use facts and rules. A fact is a piece of

information that is inherently true, and does not need to be proven. A rule contains two

pieces of information, a head and a body. The head of the rule, contains query information

that is yet to be proven. To prove the head of the rule, the body of the rule has to be

proven. The body of the rule can contain other rules and facts that have to be queried

in order to prove the head.

Prolog is a general purpose logic programming language. Prolog uses a declarative

programming style where the program logic is expressed in terms of relations, represented

as facts and rules. A computation is initiated by running a query over these relations.

Several Prolog implementations exist, such as SWI-Prolog, ECLiPSe, SICStus and

GNU Prolog. We will be using the open-source implementation of SWI-Prolog.

specifies the properties of a correct answer (for example, by using rules); depending

on these properties, a certain computation is carried out by the underlying engine for

obtaining the solution.

Logic programming languages commonly use facts and rules. A fact is a piece of

information that is inherently true, and does not need to be proven. A rule contains two

pieces of information, a head and a body. The head of the rule, contains query information

that is yet to be proven. To prove the head of the rule, the body of the rule has to be

proven. The body of the rule can contain other rules and facts that have to be queried

in order to prove the head.

Prolog is a general purpose logic programming language. Prolog uses a declarative

programming style where the program logic is expressed in terms of relations, represented

as facts and rules. A computation is initiated by running a query over these relations.

Several Prolog implementations exist, such as SWI-Prolog, ECLiPSe, SICStus and

GNU Prolog. We will be using the open-source implementation of SWI-Prolog.