One of the great schisms in the Lisp community is if we should have car and cdr or first and rest. One of the benefits of the traditional car and cdr is that we can combine them to produce pronoucible functions like cdaddr. How do Lisps that do not use car and cdr, such as Clojure, typically form combinations like this with first and rest? Is there any consensus?
How do lisps that prefer first and rest to car and cdr approach combinations like cdaddr?
304 Views Asked by J. Mini At
1
There are 1 best solutions below
Related Questions in LIST
- How to give the player the ability to choose a grid in Battleship?
- Sorting a List by its property renames all the objects in the List
- Replace NA in list of dfs in certain columns and under certain conditions
- Why does print(list.sort()) result in None?
- How to distribute the sum of several numbers similarly?
- Random getting value from a range or a specific value
- drop down list to decide which range my graph will plot
- List > numpy.ndarray using np.array(list) not working in class __init__ . Problem with numpy?
- Creating an efficent and time-saving algorithm to find difference between greater than and lesser than combination
- Flutter: How to add items and save it in local storage?
- Why my code is working on everything except one instance?
- Why does the following code detect this matrix as a non-singular matrix?
- How do I convert a list of chars into a list of strings in F#?
- Going back to an earlier index in list iteration
- If the element(s) in the first list equal element(s) of the second list, replace with element(s) of the third list
Related Questions in CLOJURE
- SSE implementation in Pedestal using individual channel per user
- Within a Clojure project using deps.edn, where is the package name and version tracked?
- How can I update and iterate the sub maps and update map into different location of map at the same time in clojure
- Out of memory in clojure - Nested reduce on Lazy Sequence
- Mac OS X - Brew installed Leiningen permission error / wrong directory
- Consume SpiceDB LookupResources gRPC stream from Clojure using Java gRPC library
- Server sent events in pedestal returns empty response
- How to make quarkus find my Clojure classes?
- Looking for a Clojure/LISP equivalent to Scons
- lazily calling functions for infinite sequence clojure
- Issue with Kafka in Clojure Repl for Arm64 M1
- Unable write parser where the AST can be turned into Clojure code
- Naming convention for simbol of clojure.core/atom, like !foo in Clojure
- How to nest a sequence of layered steps?
- How to type hint a float?
Related Questions in LISP
- How to copy and paste an autocad table using python
- common lisp type vector of fixnums
- LISP to Batchplot (Publish) Multiple .dwg Models into One PDF
- Make changes to a LISP code for AutoCAD, it is possible?
- FeatureLines civil3d
- Detecting shared structure in tree made of cons cells
- How to load FRL into Clisp?
- Scheme Question - How can I check if there are a list of pairs
- do v. do*: Why does the same code produce a different result?
- undefined variable: COMMON-LISP:PROGN when running DO
- Making an SBCL program stop
- Getting arguments from the command line within SBCL
- "undefined variable: COMMON-LISP-USER::PRIMELIST" warning, using SBCL
- Counting vowels in Lisp
- Exercise 12.10 from the book Scheme and the art of programming
Related Questions in CONS
- Prolog lists: combination of comma and |
- Convert nested hash-tables to a-list how to ensure the creation dotted pairs
- Is it possible to use 'append' or 'cons' to create a make-list function in Scheme that repeats values based on a given size parameter?
- It is possible to implement a Cons list in Rust wthout using a smart pointer
- Dotted list in lisp
- How to convert a Tree in Haskell to a flat list
- How can i write a function which extracts the nth element of a list?
- R Error:cons memory exhausted ~530GB of 1.35TB avail RAM, why?
- What do cons cells store in R?
- Every solution that I've seen for SICP Exercise 3.16 appears to cheat by creating more than three pairs. Where is my misunderstanding?
- Add elements from a list to associative list in correct format in lisp
- Could these be used as Racket definitions for cons, first, and rest?
- How to pop a value from cons list?
- How does Cons save data (Rust Linked List)
- Using function pointers as part of a linked list
Related Questions in CDR
- Automate a task of editing cdr files in c# using corel draw type library
- What is the result of this in scheme: (cdr '((a b c d)))
- How to make call records to show up on the web page (Asterisk CDR)?
- CDR ASN1 decode failed (python - asn1tools)
- Java read .cdr-File
- freepbx. Significant call time with BUSY status
- How to fix line breaks in the text cdr file?
- Can a macro be used to make c[...]r combinations with any arbitrary number of car and cdr calls, such as cadaddr?
- How do lisps that prefer first and rest to car and cdr approach combinations like cdaddr?
- How can write a program in scheme to find factors of a list of integer? how can extend it into arbitrarily large input?
- How can write a program in scheme to find factors of a list of numbers
- AWS Cognito OIDC Customizations
- Kamailio 5.4 Send CDR data to an API endpoint
- Python: functional programming with cons, car & cdr
- missing ringing call in cdr table for asterisk voip
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular # Hahtags
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
Clojure, at any rate, simply has no need for caddaadr and friends, because nobody builds data structures out of just cons cells. The language does have combinations of any two of
firstandnext, namedffirst,fnext,nnext, andnfirst, which were added very early on I suppose because it was assumed we'd want something like cadr, but I never see them used in real life. Instead destructuring is used quite often.On the rare occasions where you need to reach deeply into a structure built of nested sequences, destructuring often still produces readable code but also writing it out longhand is no great burden. It's also a good hint to you that maybe you should abstract thing a bit more rather than working with so many layers of primitive combinators directly.