1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Alona [7]
4 years ago
5

What are the differences betweenCONS, LIST, and APPEND?

Computers and Technology
1 answer:
den301095 [7]4 years ago
6 0

Answer:

These all are constructors.

<u>CONS</u>

(CONS A B)

makes a pair like this:   (A . B)  

In other words, A is the CAR of the pair; B is the CDR of the pair.

For  example:

(CONS 4 5) ==> (4 . 5)

(CONS 4 '(5 6)) ==> (4 5 6)

[The pair (4 . (5 6)) is the same thing as (4 5 6)].

<u>APPEND  </u>

(APPEND A B)

makes a new list by replacing the final nil in A with the list B. A and  

B must be proper lists.

For example:

(APPEND '(4) '(5 6)) ==> (4 5 6)

This takes any amount of number and put in this order

<u>LIST  </u>

In this ,it will return a list whose elements are value of arguments in the order as it appeared in the LIST.It can take any amount of parameters

For example,

(LIST 4) ==> (4)

(LIST 4 5) ==> (4 5)

(LIST 4 5 '(6 7)) ==> (4 5 (6 7))

(LIST (+ 5 6)(* 5 6)) ==> (8 9)

You might be interested in
What can visible light and ultraviolet light do together
jonny [76]

Explanation:

the question does not have an answer probably what they have in common

5 0
3 years ago
The reader can tell from the Article that __________.
Dmitry_Shevchenko [17]

Answer:

D. NASA would have preferred that the process for making trajectory calculations during the 1930s and 1940s had not been brought to light.

7 0
2 years ago
Question very important cause after my school is over at 5 'oclock I will be playing rocket league if anyone wants to play just
jarptica [38.1K]

Answer:

So can u tell me wut is ur question...It is not understandable

6 0
3 years ago
What is a short example of public domain?
ikadub [295]
Something that isn't subject to copyright.
6 0
3 years ago
What are two benefits of a cloud based system
rewona [7]

Answer:

1 - Reduced resource costs used for data backup.

2 - Improved collaborative work process.

7 0
3 years ago
Read 2 more answers
Other questions:
  • Every preprocessing directive must begin with:
    11·1 answer
  • Who invented the first RAM stick
    11·1 answer
  • What is the definition of “potential energy”?
    6·1 answer
  • To delete a row, you must first
    8·1 answer
  • Mrs. Sims polled her students about which social media app they use most. Which type of chart would best display this data?
    9·1 answer
  • True or false for a given set of input values, a nand
    7·1 answer
  • State whether the following statement are true or false​
    6·1 answer
  • Why is UPS necessary to connect with the computer​
    11·1 answer
  • what stage is the most inner part of the web architecture where data such as, customer names, address, account numbers, and cred
    11·1 answer
  • Pls anyone answer this Resource sharing is the need of network because?
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!