In “cuts” what is the Parent goal in Prolog?



 In “cuts” what is the Parent goal in Prolog?..

Answer / chaitanya

When running the subgoals in a rule’s body, the parent goal is referred to the goal that caused the matching of the head of the current rule.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More AI Languages Interview Questions

 What is the output of the following statement? * (setf meals ‘(breakfast lunch tea dinner)) * (cons (first meals) (last meals)) a) Breakfast b) Lunch c) Dinner d) Both a & c

1 Answers  


What is the output of the following statement? * (setf p .6) * (cond ((> p .75) ‘very-likely)((> p .5) ‘likely)((> p .25) ‘unlikely)(t ‘very-unlikely)) a) Very-likely b) Likely c) Unlikely d) Very-unlikely

1 Answers  


 Explain what is recursion in Prolog?

1 Answers  


Which is used to represent the prompt in lisp? a) # b) $ c) & d) *

1 Answers  


 What is the process of creating new data types in lisp? a) List b) Structures c) Procedures d) None of the mentioned

1 Answers  






 Which can be represented in bytes in LISP? a) Boxes and pointers b) Lists c) Lisp d) None of the mentioned

1 Answers  


 Explain what is SWI-Prolog?

1 Answers  


Which forms can be constructed with the same primitives that manipulate lisp expressions? a) Lisp b) Macro c) Procedure d) Defun

1 Answers  


What is the output of the following statement? * (defun book-author (book) (second book)) * (setf book-example-1 ‘((Artificial Intelligence) (Patrick) (Technical AI))) * (book-author book-example-1) a) Artificial Intelligence b) Patrick c) Technical AI d) None of the mentioned

1 Answers  


 What is the output of the given statement? * (setf day-or-date ‘monday) * (if (symbolp day-or-date) ‘day ‘date) a) Monday b) Day c) Date d) None of the mentioned

1 Answers  


 What is the output of the following statement? * (cdr ‘(a b c)) a) a b) B c) (B C) D) None of the mentioned

1 Answers  


Which is used to seperate the abstraction layers? a) Abstraction boundaries b) Data c) Procedure d) All of the mentioned

1 Answers  


Categories