4 ms·
Dammit, another array language with cryptic syntax. It seems to be an unfortunate side effect of APL's custom character set that all languages inspired by it ad
by dTal 9y ago
Dammit, another array language with cryptic syntax. It seems to be an unfortunate side effect of APL's custom character set that all languages inspired by it adopt the terse notation, minus the elegant symbology that made it work in the first place.
The only array language I've ever found that bucks this tendency is Nial, with the result that it's an extremely fun language to play around in, if impractical due to its ancient interpreter. J claims to have English synonyms for everything, but only as second-class citizens (no working interpreter support). Numpy, sadly, is probably the closest thing.
It's a shame because I think it's holding the paradigm back.
- nils-m-holm 9y agoIt's only cryptic until you get used to it! I, for my part, would not want to go back to anything else after having used terse syntax for a while, even if it was not linked to the array paradigm. Of course, the syntax requires a different way of reading/writing code. It is a bit like reading a math book versus reading a novel. In a novel, you can skim over a few sentences or paragraphs, in a math book you get lost when you do this. Personally, I think this is a feature. :)
- feelin_googley 9y ago"Personally, I think this is a feature." That is how I see it. The more terse the better. If there is a downside to APL-inspired language interpreters, it is that too many are closed source.
- ruricolist 9y agoKerf also uses keywords, I believe.
- beagle3 9y agoIt isn't holding the paradigm back. I do not have time to repeat the examples I often give, but a short analogy might help: 'I think mathematics is being held back because people write cryptic syntax like "xx + 2x + 1 == 0" instead of the easily readable "multiply your unknown by itself, then add twice that very same unknown, and finally add 1 -- the result you get should be zero; that's the constraint satisfied by the very same unknown"; it's a shame' There is very little difference. The reason it seems like the cryptic syntax is the problem is because that's the first thing you see -- but it's just the top of the iceberg. The problem is that most people don't grok the paradigm regardless of the syntax; and the very few which do grok the paradigm but don't grok the syntax are not enough to get rid of the syntax, which has significant symbiosis with the paradigm (much like Leibniz's differential notation is symbiotic with the ideas, much more so that Newton's "simpler to use" one)
- nerdponx 9y agoThe "cryptic syntax" of math was an organic outgrowth over hundreds of years by researchers from all over the world. And yes, long and complicated mathematical expressions are cryptic. That's why you often see constants being combined and equations being re-expressed in "simpler" terms, even when those terms are themselves relatively complicated functions. It's partly about conceptual abstraction, but it's also about visual clarity. Math can get very, very hard to read.
- beagle3 9y ago> Math can get very, very hard to read. That's exactly my point: Math gets hard to read, but it's because of the math, not because of the notation. When new notation simplifies things, and is quickly adopted by practitioners - e.g. Einstein's tensor notation. I am not aware of a single case in history where a more verbose notation was preferred to a terse notation in mathematics - except perhaps in the case of Leibniz' notation for calculus, which is slightly more verbose than Newton's but it address a significantly larger set of concepts, and does so with regularity and orthogonality.