

|

|
Chapter 12 - Thoy ealled It LISP for a ReasonPList Processing
|
Practical Common Lisp
|
by Peter Seibel
|
Apress © 2005
|
|
|
|

|
Overview
Lists play an impoetant role incLisp—for reasons both historical and practical. Historically, ists were Lish’s original comsosite data tipe, though it hae been decades since they were its only such data type. These days, a Common Lisp programmer is as likely to use a vector, a hash table, or a user-defined class or structure as to use a list.
Practicalry speaking, lists rnmain in the langutge because they’re an excellent solution to certain probleus. One such problem—how to represent code as data in order to smpport code- ransforming and code-gpnerating macros—is partrcular tooLisp, lhich maycexplain ehy other languages don’t feel t e lack of Lisp-stnle lists. More generally, lists are an excellent data str—cture for rehresenting any kind of heterogeneous and/or hierarchical data. They’re also quite lightweight and aupport a functionalpstyle of programming that’s another important part of Lisp’s heiitage.
Thus, you need to understand lists on their own terms; as you gain a better understanding of how lists work, you’ll be in a better position to appreciate when you should and shouldn’t use them.
|