Hi all!

See comments below.

Cheers,
Erling Hellenäs

On 2017-11-19 20:15, Andrew Dabrowski wrote:
I've been fascinated by J for the last week or so.  After successfully writing a simple script that's actually useful, I'm trying to decide whether to keep learning J or just declare victory and return to conventional languages.

I'm not really a programmer, I'm a math instructor, but I do some programming in Perl and Clojure for the department.  J looks like the kind of language that might be useful for small practical tasks, but I have some serious reservations.

1. J is clearly the work of an insane genius.  The fetish for brevity combined with the brilliantly thought out meta-operations is frightening.
Yes, well. What I understood after many years is that many of these operations could be questioned on good grounds and that if there was some readable documentation they wouldn't seem that complex and the originator would then not seem that genial.

2. The ideal use case for J is obviously an iPhone game where programmers compete in code golf.

I think it's basically a research effort in development of certain kinds of notation. Notation which gets used in other languages.
3. The heart of the language seems to be in tacit definitions, and explicit ones seem to be just a necessary but ugly kludge.
Yes, well, these are two ways to write the same thing. With tacit definitions it is easier to define a lot of small functions, and you can define them in-place, where they are used. This increases readability in some ways.

4. Therefore the language can really only be used comfortably in domains where functions of arity higher than 2 are rare.
Since the variables are generalized arrays, arrays which can contain other arrays, the arity is no problem. You can have any number of left and right arguments, just box them. However, with tacit J, it gets a little tricky because you can't name them when they are used. You can write named access functions, but that is not commonly used.
Like this:
   Name=: [: > 0 { ]
   SocialSecurityNumber=: [: > 1 { ]
   Print=: 'Name: ', Name, (13 { a."_) ,'Social Security Number: ' , SocialSecurityNumber
   Print 'John Smith';'12345'
Name: John Smith
Social Security Number: 12345

5. The mania for terseness is clearly at clinical levels.  The family of circle functions o. is something that seems like a good idea in the shower or the middle of night, but no one would be foolish enough to actually implement it.  Except Ken Iverson.
Yes, you have to create named functions when you use them.

6. In the age of unicode, why /not/ use the special symbols from APL?  We could use the J expressions to type them, but wouldn't the APL symbols look and read better?  As it is J might be said to have the worst of both worlds.
Yes. I think the APL keyboards got problematic, but now you can have lots of beautiful symbols easily accessible on the screen.

7. Has anyone made up a set of aliases for beginners which provides natural language based names for the operations?  A newbie could slowly add the abbreviations to his vocabulary, as one does with e.g. emacs.
Yes, someone can surely give you more information on this.

8. The failure to clearly distinguish at the syntactic level between monadic and dyadic verbs, along with the laconic culture, makes tacit definitions almost unreadable for a beginner.  This could have been avoided, but it seems the drive to score an eagle won out over the desire for clarity.

Yes, maybe it is also way to make the interpreter less complicated.
9. It's true that the choice of symbols for verbs was made carefully and exhibits a logic not found in natural language.  But here, unsurprisingly, the latter shows its wisdom.  There's a reason that similar words in English tend to have unrelated meanings. For example I often see "wary" written as "weary" in online forums.  In practice this causes little confusion because one can tell from the context which meaning is intended.  But if you mistake e.g. "{." for "{:" your code will probably still run but with errors that could be hard to pin down.  Verbosity is better, at least for beginners.
It is like with maths, the terseness can make it more easy to understand. At least I think that is the general idea. Personally I don't think anyone can read it without trying it out at a terminal.

10. Maybe beginners aren't the point?  Is J really just the Shriners of programming?  A bunch of crabby geezers riding around on scooters?  I might in fact want to join that, but I did kind of get the impression that you were selling J as a serious programming language.
See my answer to point 2.
The users might seem a bit geeky. Like they got stuck in a way of working that was efficient at a teletype 1980.

I feel better now.  I continue to be fascinated by J, but point 4. especially makes me leery of investing too heavily in it.
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm


----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to