Explain what is recursion in Prolog?
Answer / chaitanya
In any language, a function that can call itself until the goal has been succeed is referred as recursion. In Prolog, recursion happens when a predicate contains a goal that refers to itself.
Is This Answer Correct ? | 0 Yes | 0 No |
What is the output of the given statement in LISP? * (setf part (make-array ‘(8 8))) a) 8 b) 0 0 0 0 0 0 0 0 c) 0 0 0 0 d) 8 rows of 0
Which require sophisticated precedence compputation? a) Superclass b) Multiple Superclass c) Subclass d) None of the mentioned
What is the output of the given statement in LISP? * (setf abc ‘(a b c) xyz ‘(x y z)) * abc a) A b) B c) ABC
How many access procedures are avilable in lisp? a) 1 b) 2 c) 3 d) 4
What is the output of the given statement? * (defclass article() ((title :accessor article-title :initarg :title) (author :accessor article-author :initarg :author))) * (defclass computer-article (article) ()) * (defclass business-article (article) ()) * (defclass political-article (article) ()) * (setf articles (list (make-instance ‘business-article :title “Memory Prices down”))) a) Business article b) Political article c) Business article
Which is present in the writer procedure for arrays in LISP? a) Setf b) Aref c) Fref d) Both a & b
. What is the output of the given statement? * (defstruct employee (length-of-service 0) (payment ‘salary)) * (setf employee-example (make-employee)) * (employee-length-of-service employee-example) a) T b) NIL c) 0 d) Error
What is the value of last consequent form in the triggered clause? a) Value of the entire COND b) Trigger c) Consequent d) All of the mentioned
What is the output of the given statement? * (evenp (* 10 8 6 4 2)) a) T b) F c) NIL d) All of the mentioned
What is the output of the given statement? * (defstruct person (sex nil) (personality ‘nice)) * (setf person-instance-1 (make-person)) * (setf person-instance-2 (make-person :sex ‘female)) * (person-p ‘(this is a list — not a person instance)) a) Female b) Nice c) T d) Nil
Tell Me In Autocad Software How Can U Find All Command List And How Can You Change Them Like L For Line After Changing You Can Use LLP As a Line Command
Explain what is setq is used for in LISP?