WolframLang: No Reference Concept in List

By Xah Lee. Date: . Last updated: .

No Reference Concept in WolframLang

in WolframLang, there is no concept of “reference”, every Expression (list or nested list) is literal.

In Python, JavaScript, Golang, Java, etc, list-like type has a value that's a “reference”. The reference concept for lists create a lot identity problems, especially when lists are nested, such as deep copy, shallow copy, clear vs reset, changing a copy changes the original, complex meaning mutability (e.g. in JavaScript, array can be assigned to a constant, yet array element or length can still change, because the “reference” remained constant.) etc.

These problems do not occur in WolframLang.

WolframLang List