Archive for November, 2021

Understanding the “unify” Function in “newLisp”

Written by on November 28, 2021 in newLisp, Programming with 0 Comments
Understanding the “unify” Function in “newLisp”

Unification between two symbolic expressions involves finding substitutions for variables (if any) in the expressions such that the expressions match¬†after applying the substitutions. This is a powerful idea and is quite common in logic programming languages such as Prolog. Interestingly, “newLisp” has a buil-in function called “unify” that can be used for unifying two expressions. […]

Continue Reading

Currying in “newLisp”

Written by on November 14, 2021 in newLisp, Programming with 0 Comments
Currying in “newLisp”

In the last two articles, I discussed what I believe are some interesting features of “newLisp”. Today’s topic is “currying”, another useful feature. For those of you who are new to this topic, I had earlier written about “currying” in Mathematica here. You may want to take a look at that too. Unlike, for example, […]

Continue Reading

Implicit Indexing and Slicing in “newLisp”

Written by on November 1, 2021 in newLisp, Programming with 0 Comments
Implicit Indexing and Slicing in “newLisp”

In traditional Lisp (Common Lisp), when evaluating an S-expression list, the first element in the “functor” position must be a function or valid operator. newLisp¬†relaxes this requirement and allows the first element to be a context symbol type, a list, an array, or an integer. For today’s discussion, let us ignore the context symbol, but […]

Continue Reading

Top