Question: Given the logic program p(X): X=f(Y), q(X). p(X):- X=g(Y), q(X). q(X):- X=g(a). q(X):- X=g(b). Which of the following is a solution of the query:

Given the logic program p(X): X=f(Y), q(X). p(X):- X=g(Y), q(X). q(X):- X=g(a). q(X):- X=g(b). Which of the

Given the logic program p(X): X=f(Y), q(X). p(X):- X=g(Y), q(X). q(X):- X=g(a). q(X):- X=g(b). Which of the following is a solution of the query: ?-p(Z). OZ = g(b). OZ = f(a). OX= g(b).

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

The detailed answer for the above question is provided below This question involves a logic program ... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!