User Tools

Site Tools


ch1_4_conscells

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
ch1_4_conscells [2024/05/04 10:25] adminch1_4_conscells [2024/05/05 11:23] (current) admin
Line 15: Line 15:
 {{ :wiki:abcd_list_cons.png?200 |}} {{ :wiki:abcd_list_cons.png?200 |}}
  
-Proper list ends with a conscell, which has ''NIL'' in //cdr//.+Proper list ends with a conscell, which has ''NIL'' (null pointer) in //cdr//.
  
 Lisp allows us to construct list directly using ''CONS'' function. Lisp allows us to construct list directly using ''CONS'' function.
Line 33: Line 33:
 (A B C) (A B C)
 </code>  </code> 
 +
 +The power and simplicity of Lisp originates from the fact that code is a list of lists and atoms, exactly the same structure connected with conscells, as is any user-defined data list. Lisp macros can manipulate the code using any of the functions that manipulate data lists.
  
 FIXME FIXME
Line 38: Line 40:
 Show more examples, cons, car, cdr, link to List Processing Functions. Show more examples, cons, car, cdr, link to List Processing Functions.
 Show functionality of accessors and SETF shenanigans. Link to Cycles. Show functionality of accessors and SETF shenanigans. Link to Cycles.
 +Dotting.
 +Show list with nil element, or (nil) sublist.
  
  
ch1_4_conscells.1714839958.txt.gz · Last modified: 2024/05/04 10:25 by admin

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki