Discuss and learn Lisp programming of all dialects
This is a read-only archive of lispforum.com. The forum was locked to new users and
posts and is preserved here as static HTML from a database snapshot taken on
2019-09-07.
Write a recursive function.
When descending the tree,
- if the node is an integer, return it
- if the node is a list, take the operator, recurse into the children, then evaluate the operator, and return the evaluated list
When evaluating the operator, the evaluated argument nodes are either values or lists with the value in the first entry
I'm a complete beginner at this and have no clue how to do any of that. There isn't really much material online to help figure this out. Any chance you could give me a bit more of a push in the right direction on how to do that?