CSCI 431: Logic Programming

(This presentation is taken primarily taken from an Introduction to Prolog by Paul Brna and Tamsin Treasure-Jones at http://cbl.leeds.ac.uk/~tamsin/prologtutorial.)

What is Prolog?

Prolog as a Programming Language

So, what's a declarative language?

What does a declarative program look like?

And what's a relational program?

A little history

Simple Facts

Examples of Simple Facts

Facts with Arguments

Examples of Facts with Arguments

More Examples of Facts with Arguments

Variables and Unification

Variable Examples

More Examples of Variables

Rules

Rules Part 2:

Rules Part 3

Rules Part 4

Rules Part 5

Examples of Rules

More Examples of Rules

Introducing Backtracking

Backtracking in Rules

Search Example Part 1

Search Example Part 2

Search Example Part 3

Search Example Part 4

Search Example Part 5

Lists

List Examples 1

List Example 2