by cardanome · 2y ago · 0 comments
Classical Math notation is full of weird Greek symbols and absolutely incomprehensible without any training. APL is way more regular and easier to grok as well as to type on computers.
With it's small set of special symbols, regular syntax and human-friendly infix notation APL is designed be very easy to learn.
It looks utterly alien to programmers that are used to the C-style syntax based languages, yes. but your JS or C# code looks as alien if not more alien to an non-programmer as does APL to you.
I am not convinced that APL is harder to learn that JS for non-programmers. I think existing programmer struggle way more with learning APL because it requires them to unlearn certain ideas.
As you might guess from my original post, I'm a Lisp apologist. I like the syntax and I can make an argument for Lisp [1] that sounds a lot like the argument you make here for APL. From what you say and from what I've read, I suspect APL is another language like Lisp (and Smalltalk, Forth, and Tcl). These are all languages derive a great deal of elegance and coherence from a pure approach to syntax and design, and all are seductive in their way to people that have taken on the effort to learn how they work.
The problem is that this doesn't matter enough to overcome the incumbency bias in favor of more traditional languages.
> but your JS or C# code looks as alien if not more alien to an non-programmer as does APL to you.
It would be convenient for APL if this were true, but the reality is that it's not.
I learned Logo and Basic when I was eight. My kids learned JS/Python around the same age. This is a common experience. It's just not that hard to learn basic imperative programming in an infix language.
When I was learning programming back then, those keywords could just as well have been single letters. It wouldn’t have made a difference.
Also, I went up to my printer and there is no “WTF” there. Surely, this program doesn’t work! More seriously, this just illustrates that convention and idioms are much more powerful carriers of meaning than dictionary words. Array languages rely heavily on conventions/idioms.
This is the experience of learning to read music without speaking Italian. "Allegro ma non troppo" doesn't mean much in English.
As for expecting "print" to go to printer, I doubt that's the default expectation of anyone under the age of ~35 at this point.
Array languages rely heavily on idiosyncratic conventions/idioms that are utterly alien to all outsiders. Hence why they don't see uptake, and that is not going to change until their proponents are going to take this seriously. This all reminds me how Lisp adherents keep saying that syntax doesn't matter, except, looking at the actual adoption of Lisp, it evidently does. You are not going to convince everyone else to learn to "hold it the right way".
It demonstrates that your criticism of the syntax of array languages boils down to “it’s different than the things I already know” and that not using words in a programming language isn’t a meaningful barrier to most people, given that most programmers in the world overcame this obstacle with no sweat. There is a meaningful criticism to be had in the area of syntax, but this is not it IMO. One valid criticism I know of is that most array languages have a context-sensitive syntax: you need to maintain a symbol table in your head to know how to parenthesise a line of code. Fortunately, BQN fixes this issue by using a context-free grammar.
Lisp is defined by much more than syntax. I certainly see many flaws in it (starting with the cons cell), which are total deal-breakers for me and have nothing to do with syntax. I think your view that syntax is the biggest obstacle to Lisp’s popularity isn’t as evident as you claim. There are too many other, IMO bigger obstacles.