GB
  
You are currently viewing the United Kingdom version of the site.
Would you like to switch to your local site?
16 MIN READ TIME

CLASSIC LANGUAGES

APL: going strong after all these years

It might be almost 60 years old, but the APL programming language continues to have an enthusiastic following, as Mike Bedford reveals.

OUR EXPERT

Mike Bedford might not use it in anger, but he’s been fascinated by APL’s quirkiness since he first saw how it could generate prime numbers in just 20 characters.

QUICK TIP

The abandonment of strange symbols in later Iversonian languages, such as J and K, has been considered a retrograde step by some APL diehards. However, the BQN array processing language, introduced in 2020, makes a return to the use of largely unfamiliar symbols.

The classic IBM 5110 luggable, as we discovered in LXF291, ran APL, which stands for A Programming Language, yes really. Despite APL – according to the TIOBE index of the popularity of programming languages – languishing somewhere between the 50th and 100th positions, we were surprised to find that APL still has an enthusiastic following among enthusiasts and for developing commercial applications.

As always, the unexpected is the trigger for articles, and we’re delving into classic programming languages and why some coders choose APL over today’s latest and greatest languages, and what types of application benefit from its different approach to problem solving.

APL overview

Before starting to look at how and why APL is used today, we ought to paint a picture of it. Common descriptions range from unusual to downright bizarre. In fact, a professor of computer science at an American university is on record as saying that “APL is a language designed by a mad-man”. Part of the reason that APL is considered strange is its use of special symbols, instead of keywords, for many of its functions. We also have to say that it is terse in the extreme, as you can see from the following hieroglyphics: , which is a variant of the commonly cited code for displaying all prime numbers up to a maximum of X. Part of the reason that APL code is so concise is that, although some newer variants have added them, the original APL barely had any conditional or flow control statements, and APL code is still commonly written in that way. This omission is because it’s an array processing language. In other words, it can handle many of its operations on arrays, natively, which often eliminates the need for statements that are essential in other languages. APL is normally an interpreted language, too. When we also remember that so many jobs that would require many lines of code in most languages can be achieved on a single line, we can see why it’s sometimes been referred to as a glorified calculator.

APL’s first major implementation was for IBM 360 series mainframes, a paradigm shift from Fortran and COBOL, the workhorses of ’60s and ’70s mainframes.

While APL is, arguably, the best-known array processing language, it’s not the only one. In our discussion of APL, therefore, we’re including two more, which go by the imaginative names of J and K, and are sometimes referred to as Iversonian languages after Ken Iverson who developed APL. In many ways, J and K are similar to APL, although they don’t preserve APL’s use of a non-standard character set. However, they still don’t make extensive use of keywords and, instead, those strange looking characters in APL become ASCII characters, either singly or in combination.

Unlock this article and much more with
You can enjoy:
Enjoy this edition in full
Instant access to 600+ titles
Thousands of back issues
No contract or commitment
Try for 99p
SUBSCRIBE NOW
30 day trial, then just £9.99 / month. Cancel anytime. New subscribers only.


Learn more
Pocketmags Plus
Pocketmags Plus

This article is from...


View Issues
Linux Format
April 2023
VIEW IN STORE

Other Articles in this Issue


LINUX FORMAT
SUBSCRIBE!
WELCOME
MEET THE TEAM
300 issues of Linux Format – can you believe it? What are your predictions for Linux or your favourite open source project over the next 300 issues?
Freed software
Saying “free software” has always caused confusion. Most
REGULARS AT A GLANCE
Newsdesk
THIS ISSUE: Li bre Office upgrade New Plasma due to hit screens Cool phase of Debian 12 Non-GNU Linux
POD BOD
Jon Masters is a kernel hacker who’s been
Kernel Watch
Jon Masters keeps an eye out for all the latest happenings in the Linux kernel, so you don’t have to.
Answers
Got a burning question about open source or the kernel? Whatever your level, email it to answers@linuxformat.com
Mailserver
WRITE TO US Do you have a burning
BACK ISSUES MISSED ONE?
ISSUE 299 March 2023 Product code: LXFDB0299 In
OpenShot
Version : 3.0.0 Web : www.openshot.org These
Rsync
Version : 3.2.7 Web : https://rsync.samba.org Linux
Aria2
Version : 1.36.0 Web: https://aria2.github.io No
Claws Mail
Version : 4.1.1 Web : www.claws-mail.org C
Akregator
Version : 5.22.1 Web : https://apps.kde.org/akregator If
Konqueror
Version : 22.12.1 Web : https://apps.kde.org/konqueror Unless
Pidgin
Version : 2.14.12 Web : https://pidgin.im A
FlightGear
Version : 2020.3.17 Web : www.flightgear.org F
SuperTuxKart
Version : 1.4 Web : https://supertuxkart.net As
Qemu
Version : 7.2.0 Web : www.qemu.org Q
CPU-X
Version : 4.5.2 Web : https://thetumultu ousunicornofdarkness.github.io/CPU-X
SAVE YOUR OLD PCS!
We help keep the lights on by running your old hardware for longer: easy upgrades and 32-bit installs galore!
LINUX FORMAT
The #1 open source mag Future Publishing Limited,
CLASSIC RETRO REVIEWS
REVIEWS
Corel Linux 1.0
Debian GNU/Linux 2.1
It may be a bit behind the times, but Debian is one of the best distributions on the market.
SUSE Linux 6.3
We test this long-established German company’s latest distribution effort. Can it hold off the competition?
Ubuntu 5.04
Andy Hudson hopes this is one hedgehog that won’t get squashed.
Linux-Mandrake 7
Simplicity and a wide range of applications make this a great distribution for all Linux users.
ROUNDUP
Key Linux distros
There are Linux distros aplenty, but Mayank Sharma is on the lookout for the ones that play a key role in the Linux-sphere.
Installation media and mechanisms
For anchoring them to your disks.
Customisability & administration
Mould them to your liking.
The end user experience
How does it all come together?
Reach and appeal
Who do they target?
Help and support
What do you do if you’re stuck?
Spins and derivatives
Can I pimp my ride?
Package management
Want to flesh out your installation?
The Verdict
Key Linux distros
ALSO CONSIDER
Two distros that have created an identity for
The Best OPEN SOURCE Software Ever!
In an attempt to trigger controversy, Michael Reed and Neil Mohr unequivocally state these are the greatest free software apps ever. Probably. We’re just trying to be helpful.
Top of the FOSS!
Some of the most notable projects in history.
THE OLDEST OF OPEN SOURCE…
Open a terminal and you have access to
GIMP 2.10.32
If you want to work with image processing, GIMP should be your first port of call.
Ardour 7.2
It’s the most fully featured open source digital audio workstation (DAW) on Linux.
Wireshark 4.0.2
Makes it easy to see the sensitive data travelling around your network.
LibreOffice 7.5
When it comes to traditional office duties, LibreOffice covers all bases.
Visual Studio Code 1.74
When it comes to open source development tools, the first thing you need is a programmer’s editor.
Kdenlive 22.12.1
Kdenlive can handle most video-editing tasks, and new features are being added all the time.
Dolphin 22.12
With a bit of configuration, Dolphin can scale up to a power user’s tool.
Cockpit 283
Monitor a server and do maintenance via a web interface? Yes please!
Terminal tools
Think GUIs are for wimps? More of a terminal type? Try these…
Pi USER
I’m so cool I run Raspberry Pi
The Coolest Projects showcase is up and running, and open to entries.
No more blues
Perk up your APIs.
Compute this!
Rack-mountable trouble.
THE RE TURN OF CAMJAM!
Brian Corteil is a maker, amateur robot designer
Waveshare Zero to Pi3
Transform your Pi Zero into a Pi 3, they promised Les Pounder, but it’s more like adding on go-faster stripes.
Master RPi.GPIO
Les Pounder goes back to the early days of the Raspberry Pi – and his career – with this classic library!
Control your Pi robot with Bluetooth
Loving the feeling of power, Les Pounder shows us how to remote-control your robot with Android devices and Bluetooth.
Free our SOFT WARE!
Taking anything for granted is dangerous, so Jonni Bidwell and Mike Saunders revisit how the free software movement got started to help free us from proprietary tyranny!
TOP OF THE FOSS!
In 2011, boy genius Mike Saunders met Stallman at the Institute of Engineering and Technology in London, where he put to him some of the questions you’d asked…
RMS: First, I want to tell you about
Find it faster!
Traversing hundreds of GBs of data and thousands of folders is a tall order, unless you’re Shashank Sharma, who knows just the tool to find files fast.
TUTORIALS
Jump to a federated social network
Nick Peers reveals how you can get up and running with this free, decentralised and non-profit alternative to Twitter.
Runing with the GNU Debian Hurd
Matt Holder goes against the Hurd to try the other GNU kernel and a ready-built operating system to run it all.
Universal layer text effects with GIMP
Posters use them, films and presentations are hard to imagine without them: text effects. Attract attention with Karsten Günther and GIMP.
Set up your terminal and email like it’s 1983
Jump in the hot terminal time machine with Mats Tage Axelsson who emails from the command line using the latest technology.
Clang-ing the kernel
Jonni Bidwell shows you how to configure a mainline kernel, then compile it, artisan-style, with LLVM/Clang.
IN DEPTH
Fantastic Mr Firefox
Nick Peers takes a trip down memory lane to reveal the story behind the rise – and slight fall – of Mozilla’s popular web browser.
CODING ACADEMY
WEBSOCKET
Create your first WebSocket service
Write your own classic Pong game
Matt Holder takes a trip down memory lane and creates a Pong-style game, for all your retro gaming needs.
Chat
X
Pocketmags Support