Fun with Obscure Programming Languages

Author: Caitlin Moy

As a linguistics major, I’ve always loved testing the boundaries of language design, especially fascinated by constructed languages, or “conlangs.” Consciously devised languages, conlangs may be created with the intent to solve a linguistic problem in a unique way, like Esperanto, the self-proclaimed universal second language for world peace, or they may be created as an addition to a fictional environment, like Klingon, the Star Trek creation which boasts around twenty fluent speakers to date.

Programming languages, on the other hand, are all consciously devised; However, there is certainly a division between practical, widely-used languages, like Java and Python, and esoteric languages, or the computer programmer’s equivalent of a conlang. These obscure systems are rarely created with the purpose of wide-scale use, and are better known for pushing the limits of programming, proving computer science concepts, and most commonly — for jokes.

If you’ve had enough of your standard “System.out.println” statements to last a lifetime, take a look at these impractical, yet interesting, alternatives:

  1. chicken

Tired of memorizing the syntax whenever you start a new language? Chicken consists of two tokens: “chicken” and “\n” (the newline character). Invented by Torbjörn Söderstedt, the number of space-separated “chickens” per line corresponds to an opcode, a specification to the machine of the operation to be performed. The Swedish programmer was inspired to create this language after hearing software engineer Doug Zongker’s parody of scientific papers (unsurprisingly, a presentation that consisted only of the word “chicken”).

A partial Hello World program written in chicken:

Image for post
Image for post

2. chef

If you’d rather opt for a high-level language with easy readability, one might direct you to Python, but I would suggest “chef” instead. Invented by David Morgan-Mar, chef reads like a recipe, and not a program. According to the chef homepage, the language is bound by design principles such as, “program recipes should not only generate valid output, but be easy to prepare and delicious.” Valid commands include, “Take ingredient from refrigerator,” which translates to, “read a numeric value from STDIN into the ingredient named, overwriting any previous value.”

Hello World program written in chef:

Image for post
Image for post

3. legit

A hello world program written in legit looks like the following:

Image for post
Image for post

An empty file. So, if you’re a programmer who despises coding, this may be the language for you! However, if you look at the version control, you’ll find where all the inner workings reside, due to the fact that legit is defined entirely by the graph of commits in a Git repository. The creator, Sebastian Morr, was inspired to create his own esoteric language after giving a talk on the matter at his university. Additionally, due to the nature of git commands, all programs need to be written backwards, without making any errors in order to run.

4. Piet

For anyone whose eyes glaze over after staring at lines of seemingly identical code for hours, Piet is a visually pleasing alternative. Also invented by David Morgan-Mar, and named for abstract artist Piet Mondrian, this language uses combinations of twenty distinct colors laid out in a bit map, guided by the principle, “program code will be in the form of abstract art.” To operate, a pointer is used to move from region to region, along with a single stack for data storage.

Hello World program written in Piet:

Image for post
Image for post

Esolangs have little practical use, yet there is an active internet community surrounding them, creating, testing, and debating the Turing-completeness of each language. Although they may not be used anytime soon to build the next Facebook or to program your GPS, esoteric languages make us think outside the box as to what we consider the standards of programming and computer science, a field that is constantly evolving and may look entirely different in a few years. One day, you might find the source code of your web browser homepage to read something along the lines of, “chicken chicken chicken chicken chicken.”

Sources:

https://esolangs.org/wiki/Chicken

https://www.dangermouse.net/esoteric/chef.html

https://www.hongkiat.com/blog/bizarre-insane-programming-languages/

https://www.youtube.com/watch?v=yL_-1d9OSdk

https://esolangs.org/wiki/Legit

https://hackernoon.com/weird-programming-languages-that-you-may-have-not-heard-8ddce12bab66

http://www.dangermouse.net/esoteric/piet.html

Written by

An inclusive network of women in tech at Rutgers University seeking a supportive community and professional development. https://rutgerswics.org/

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store