Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Question 1 (a) Which of the following pairs of expressions are unifiable? If any pair is unifiable give the resulting bindings for the variables. Otherwise

image text in transcribed

Question 1 (a) Which of the following pairs of expressions are unifiable? If any pair is unifiable give the resulting bindings for the variables. Otherwise give reasons why the pair cannot be unified. [[a, b, c]] and [ X Y ] . [A A ] and [ X , [ c, d, ell (A, A ] and [ XI [ c, d, ell A*B+C-2+X and U+X+Y-Z (b) Assume that a Prolog database contains the following facts. p(a) q(a,1) r(1,1). r(3,5) p(b). q(a,2). r(1,2). r(3,6). q(6,3). r(2,3) r(4,7) q(6,4) r(2,4). r(4,8) What are the effects of the following queries? 1. ?- P(X),q(X,Y),',r(Y,Z). 2 - p(x), once (q(X,Y)),r(Y,Z) 3. ?- P(X),,q(X,Y). Question 1 (a) Which of the following pairs of expressions are unifiable? If any pair is unifiable give the resulting bindings for the variables. Otherwise give reasons why the pair cannot be unified. [[a, b, c]] and [ X Y ] . [A A ] and [ X , [ c, d, ell (A, A ] and [ XI [ c, d, ell A*B+C-2+X and U+X+Y-Z (b) Assume that a Prolog database contains the following facts. p(a) q(a,1) r(1,1). r(3,5) p(b). q(a,2). r(1,2). r(3,6). q(6,3). r(2,3) r(4,7) q(6,4) r(2,4). r(4,8) What are the effects of the following queries? 1. ?- P(X),q(X,Y),',r(Y,Z). 2 - p(x), once (q(X,Y)),r(Y,Z) 3. ?- P(X),,q(X,Y)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Intelligent Information And Database Systems 6th Asian Conference Aciids 2014 Bangkok Thailand April 7 9 2014 Proceedings Part I 9 2014 Proceedings Part 1 Lnai 8397

Authors: Ngoc-Thanh Nguyen ,Boonwat Attachoo ,Bogdan Trawinski ,Kulwadee Somboonviwat

2014th Edition

3319054759, 978-3319054759

More Books

Students also viewed these Databases questions

Question

What are the types of forms of communication ?

Answered: 1 week ago

Question

Explain the process of MBO

Answered: 1 week ago

Question

7. Explain why retirees may be valuable as part-time employees.

Answered: 1 week ago

Question

3. Provide advice on how to help a plateaued employee.

Answered: 1 week ago