exitaplgnu-apl

How do I exit GNU APL?


"I am stuck and cannot escape." - jclancy

I've been using Dyalog workspaces to play with APL, but wanted to try it out on the CLI, so I downloaded GNU APL from homebrew to check it out. Works great!

Unfortunately, once launched, I can't figure out how to quit or even suspend the REPL.

I have tried:

(As a workaround, kill -9 $pid did of course work and was rather satisfying).


Solution

  • It is in the docs: section 1.2. (Keywords "stop" or "exit" – you were close!)

    1.2 Starting APL

    Last things first: before explaining how to start APL, it is important to remember how to stop (i.e. exit) it. Neither ^C nor ^D will stop APL - they serve other purposes. Instead, you leave APL with the command )OFF (on a separate line) like this:

    )OFF
    

    If APL is computing a function (and possibly caught in an endless loop), then you may have to press ^C (called ATTENTION in APL) in order to return to APL’s command mode and then give the )OFF command.