Introduction to
Logic Programming
What
versus
How
 

Exercise 3.3 - Query Evaluation


What is the result of evaluating the query goal(X,Z) :- p(X,Y) & p(Y,Z) on the dataset shown below.