3 ms·
> I saw the CARs and CDRs and CADDADDRs and thought it was all just academic baloney; interesting but not truly useful. car and cdr are accessors for the field
by kazinator 7y ago
> I saw the CARs and CDRs and CADDADDRs and thought it was all just academic baloney; interesting but not truly useful.
car and cdr are accessors for the fields of a basic data-structure; nothing academic about that. The very origin of the names is rooted in systems work, not academics.
(caddr x) provides a shorthand for (car (cdr (cdr x))), which is a pragmatic thing.
You know, like #(* % %) instead of (lambda (x) (* x x)).
- jjtheblunt 7y agoi thought CAR and CDR were named after IBM (?) assembly language on an old machine. https://en.wikipedia.org/wiki/CAR_and_CDR https://en.wikipedia.org/wiki/CAR_and_CDR
- kazinator 7y agoThat's right; and that's a systems programming origin, not academics.
- kyberias 7y agoHe didn't say they are academic, he said he thought they were academic.