Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Henry,
- I offer this as tangentially responsive to your question (posted to
- jprogramming), "How do you convince someone that J is really different?"
- I'm an amateur J programmer and I think I know what makes J different. I
- still remember (rather hazily; see below) the moment when it hit me. FWIW,
- here is my conversion story.
- One evening in a midtown Manhattan bar in 1989, over the course of nearly a
- dozen pints of Guinness between us, a VP at Morgan Stanley persuaded me (a
- junior Smalltalk programmer) that APL was a gift from the gods. He told a
- wonderful story about showing it to his wife (who was struggling through a
- FORTRAN class): when she realized that she could just type in two lists of
- numbers with a “+” between them rather than declaring, assigning and
- looping, her face lit up like the very dawn. He was bitterly convinced
- that absent the unconscionable interference of Bob Frankston and Dan
- Bricklin, APL—not the spreadsheet—would have conquered the world. His name
- was R0ml (yes, that is a digit) and he was without question the smartest
- programmer who’s ever been willing to drink with me.
- The need for a custom keyboard was enough to keep my admiration for APL
- distant if sincere, but when J became available I jumped on it,
- thinking, “This
- will actually be _better_ because Ken Iverson will fix everything he
- doesn’t like about APL.” I was very enthusiastic, and remained so as I
- hunched over my machine, ruthlessly (if explicitly) dispatching toy
- problems. I found J (still the only array language I’ve studied) to be a
- towering intellectual achievement—it was clear that far more thought had
- gone into it than into any language I’d ever used. My father (proud owner
- of a threadbare “Bring Back the 7090” T-shirt) told a story about pushing
- my baby carriage down the sidewalk while reading the first FORTRAN manual,
- absolutely convinced that the mind of Man could do no more. For the first
- time, I knew how he’d felt.
- My 30 years with J have been those of an on-again-off-again hobbyist. Like
- most "J-Adjacents," I suspect, I've tried to persuade my employer of the
- moment to use it for this or that problem domain. It always went about as
- well as you might imagine.
- So what did R0ml tell me that made such a huge impression? Several
- things--none surprising to this group, each a revelation to me as we drank.
- 1. Most programming languages' primitives operate on scalars. There's
- not much you can do with scalars: add them, subtract one from another, take
- a remainder, index into an array, etc. So most programming languages
- have few primitives.
- 1. You can't accomplish much with individual scalars. You have to work
- with collections of them to get anything done. These collections are
- often arrays. If you find yourself looping, you're probably dealing
- with an array (if only implicitly).
- 1. APL's primitives operate on arrays. (Here he went through a few
- classic, eyebrow-raising examples.)
- 1. Two implications of primitives operating on arrays: first, you
- write/test/maintain a lot less code (insert canonical example of using a
- nested loop to add two vectors).
- 1. Second, because arrays are richer constructs than scalars, you can
- have a lot more primitives. That's great news for the power of the
- language (and the length of your programs) but…
- 1. …it's not the end of the story. Learning a language means learning
- (most of) its primitives, so learning APL takes (a lot) longer than
- learning a conventional language, even before you take into account the
- geometric increase in idioms. This higher threshold for competence
- turns out to be a significant barrier to adoption, despite APL's (array
- languages') obvious advantages once you're over the hump.
- And there we called it a night (he picked up the tab). I found the case he
- made clear, compelling, horizon-shattering, persuasive
- and--ultimately--somewhat discouraging. I have yet to run across one that
- I found more so.
- As I said, FWIW.
- Many thanks, Henry, for all of your technical- and pedagogical
- contributions over the decades.
- Ed
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement