Mention what are the three functions required by LISP?



Mention what are the three functions required by LISP?..

Answer / chaitanya

For defining functions, macro named defun is used, it needs three arguments
• Name of the function
• Parameters of the function
• Body of the function

Is This Answer Correct ?    2 Yes 0 No

Post New Answer

More AI Languages Interview Questions

Mention what are the three functions required by LISP?

1 Answers  


Explain what is the difference between bagof/3 and setof/3 predicate in Prolog?

1 Answers  


 How many items are available in mapping primitives are there? a) 3 b) 4 c) 5 d) 6

1 Answers  


 What is the output of the given statement? * (defstruct triangle (base 0) (altitude 0)) * (defun area (figure) (cond ((triangle-p figure) (* 1/2 (triangle-base figure) (triangle-altitude figure))))) * (setf triangle (make-triangle :base 2 :altitude 3)) * (area triangle) a) Triangle b) 7 c) 6 d) 10

1 Answers  


Mention what is Cut (!) in Prolog and what is the advantage of ‘Cut’ and ‘Negation’?

1 Answers  






 What is the output of the given statement in LISP? * (setf bins (make-array 2 :initial-element ‘e)) a) E b) E E c) E E E d) E E E E

1 Answers  


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

1 Answers  


What is the output of the given statement in LISP? * (setf fact1 ‘(big computers are nice)) * (setf (first fact1) ‘fast) a) Big computers b) Fast c) Big computers are fast d) None of the mentioned

1 Answers  


 Which can build new lists by depositing pointers in free boxes? a) Do b) Dobuild c) Cons d) None of the mentioned

1 Answers  


 Which class can help to select a method? a) Nonoptional argument b) Class c) Method d) None of the method

1 Answers  


 Which notation facilitates uniformity in lisp? a) Prefix b) Postfix c) Infix d) None of the mentioned

1 Answers  


 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)) * (setf (person-surname person-instance-1) ‘winston) a) Winston b) Nil c) T d) Error

1 Answers  


Categories