250+ TOP MCQs on List Storage and Answers

LISP Multiple Choice Questions on “List Storage”.

1. Which is a string of boxes linked by arrow like pointers?
a) Lisp
b) List
c) Variables
d) Pointers
Answer: b
Clarification: A list in box and pointer notation is a string of boxes linked by arrow like pointers.

2. What is the other name of boxes?
a) Cons cells
b) Conses
c) Both Cons cells & Conses
d) None of the mentioned
Answer: c
Clarification: The box is called as atoms and two-pointer entities, in which the boxes can tie together.

3. Which is used to construct new lists by linking the right pointers?
a) Links
b) List
c) Variables
d) Right pointers
Answer: d
Clarification: Lisp maintains a list of spare boxes, linked by their right pointers for constructing new lists.

4. Which can be represented in bytes?
a) Boxes and pointers
b) Lists
c) Lisp
d) None of the mentioned
Answer: a
Clarification: Boxes and pointers both can be represented in bytes. But lists and LISP can be represented in bytes.

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

6. What is the output of the given statement?

span class="sy0"> * (setf abc '(a b c) xyz '(x y z))
* (setf bc (rest abc))
* bc

a) A
b) B
c) C
d) BC
Answer: d
Clarification: This statement will print BC because of definied variable bc.
Output:
(B C)

  250+ TOP MCQs on Predicates and Answers

7. What is the output of the given statement?

span class="sy0"> * (setf abc '(a b c) xyz '(x y z))
* abc

a) A
b) B
c) ABC
d) None of the mentioned
Answer: c
Clarification: This statement is printing abc because of definition.
Output:
(A B C)

8. What is the output of the given statement?

span class="sy0"> * (setf toss '(heads tails tails tails heads tails))
* (delete 'heads toss)
* toss

a) Heads tails
b) Heads tails tails tails tails
c) Heads
d) None of the mentioned
Answer: b
Clarification: This statement will print the result by mainpulation of delete.
Output:
(HEADS TAILS TAILS TAILS TAILS)

9. What is the output of the given statement?

span class="sy0"> * (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
Answer: b
Clarification: This statement will print the given result because of the definition of first.
Output:
FAST

10. What is the output of the given statement?

span class="sy0"> * (setf l1 (list 'a 'b 'c))
* (setf l2 (list 'a 'b))
* (setf l1 l2)

a) A B
b) A B C
c) B C
d) None of the mentioned
Answer: a
Clarification: This statement will print the a and b because of computing the intersection of the two values.
Output:
(A B)

Global Education & Learning Series – LISP Programming Language.

Participate in the Certification contest to get free Certificate of Merit. Join our social networks below and stay updated with latest contests, veos, internships and jobs!

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top