Slashdot Mirror


What Ever Happened to APL?

geophile asks: "Is it still supported? Are there new applications being written in it? Has it been extended? Did it die? When and why? Whatever happened to those funky keyboards?" APL [?] has the distinct reputation of being one of the most cryptic programming languages ever invented, due to the fact that it's a language based entirely on symbols. Is anyone out there still using it? If so, for what types of projects?

2 of 19 comments (clear)

  1. Note by Kaufmann · · Score: 3

    APL per se uses a non-ASCII character set, which means you need a really funky keyboard. However, there's an APL variant called J which has the same semantics, but a textual (i.e. ASCII) syntax. I remember seeing a J primer somewhere on the Net; you can look for that.

    --
    To the editors: your English is as bad as your Perl. Please go back to grade school.
  2. Re:It scared me... by SIGFPE · · Score: 4
    It's probably slower that most programming languages you could find today, but it makes really small programs...
    This is often true but not for the reason you might think. In principle it should be damn fast if you have a smart optimising interpreter. APL is very good for manipulation of large matrices, say. As the code tends to be very compact the amount of time actually spent interpreting the code itself is small compared to the time spent performing the operations themselves. Also, as the operations tend to be higher level than in C, say, the interpreter has an opportunity to optimise sequences of operations and concatenate them together. In addition APL lends itself nicely to lazy evaluation. On the other hand it's often extremely easy in APL to come up with extremely inefficient algorithms that nobody would even dream of writing in C, say, but are very tempting in APL because they only require 3 or 4 keystrokes! Just a simple example: suppose you want to sum along the diagonals of a matrix - it can be easier to simply resize the matrix to be one wider or one narrower than before and then sum down the columns. With a bad APL interpreter the whole matrix has to be rearranged in memory before summing can take place. Nobody would write code like that in C. On the other hand a good APL interpreter wouldn't really rearrange the array but simply change the way the data is indexed making it potentially almost as efficient as C. I think it's the best language for numerical work and it's a hell of a shame that it's not used more. I wish there were a reasonably priced (eg. free) and easy to install APL interpreter that came with decals I could use to upgrade the keyboard!
    --
    --
    -- SIGFPE