4 ms·
Interestingly, the author mentioned both M-expressions ("never implemented") and Mathematica (with a number of interesting links). Mathematics expressions are q
by ktpsns 4y ago
Interestingly, the author mentioned both M-expressions ("never implemented") and Mathematica (with a number of interesting links). Mathematics expressions are quite close to https://en.wikipedia.org/wiki/M-expression https://en.wikipedia.org/wiki/M-expression . Function application is not (f x y) or f[x; y] but f[x, y]. In contrasts, lists in Mathematica are {1,2,3} and thus pretty close to [1;2;3]. This curly bracket list notation is already syntactic sugar, as Lists are actually List[1,2,3] and thus very transparent to how you can represent them in LISP. Mathematica introduces a number of handy abbreviations such as f@x for f[x] or {x,y,z}/.f == Map[f,{x,y,z}] == {f[x],f[y],f[z]}. It even "overloads" the double semicolon symbol ;; basically acting as as in/pre/post-fix "operator", cf. https://reference.wolfram.com/language/ref/Span.html https://reference.wolfram.com/language/ref/Span.html -- the same is true with virtually any symbol such as "==" (Equals) or "+" (Plus).
The Mathematica/Wolfram language could really be a game changer if it was open source.
- Y_Y 4y agoEven F[1,2,3] is sugar for and sexp. If you treat it like (F 1 2 3) it will work. You can take the head, or "quote" it with Hold. Or you can forget that an imagine that the language indexes from 1.
- lispm 4y ago> M-expressions ("never implemented") There were a bunch of approaches and even implemented languages. https://github.com/shaunlebron/history-of-lisp-parens/blob/master/alt-syntax.md https://github.com/shaunlebron/history-of-lisp-parens/blob/m...
- hackrnusr 4y agoIt already is: https://mathics.org/ https://mathics.org/