Jump to content

Esoteric programming language

From Wikipedia, the free encyclopedia

This is an old revision of this page, as edited by Runeberge (talk | contribs) at 11:32, 27 August 2004 (Added info about the mailinglist lang@esoteric.sange.fi). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.

Esoteric programming languages are programming languages designed as a proof of concept, or as jokes, and not with the intention of being adopted for real-world programming. Consequently, usability is rarely a high priority for such languages. The usual aim is to remove or replace conventional language features while still maintaining a language that is Turing-complete.

The earliest, and still the canonical, esoteric language was Intercal, designed in 1972 with the stated aim of being as fundamentally unlike any existing language as possible. Other noteworthy esoteric languages are:

  • Brainfuck, a Turing tarpit consisting of only eight instructions
  • Unlambda, a minimal language based on the functional programming paradigm
  • Befunge, in which programs are arranged on a two-dimensional grid
  • Malbolge, designed to be the hardest programming language ever invented.
  • The language of Tierra "organisms", which is designed to be less brittle than regular programming languages or machine codes when serving as digital DNA in an environment of competing and mutating digital "organisms".
  • Whitespace, a programming language where only whitespace (space, tab, newline) matters.

There is a small but thriving community on the internet of hobbyists who program in and design esoteric programming languages. Their main form of correspondence is through the mailing list lang(at)esoteric(dot)sange(dot)fi, as well as the secondary and more directed friends-of-brainfuck(at)koeln(dot)ccc(dot)de, which is specifically geared to Brainfuck related pursuits.

The esolang community is active sporadically, and topics of discussion range from debate as to whether or not a language is Turing-complete to how one would go about representing abstract and hard to visualise mathematical concepts in a programming environment.

Turing completeness is a favorite topic of discussion, since it is not immediately obvious whether or not a language is Turing Complete, and it often takes rather large intuitive leaps to come to a solution. New languages with new features are always being created, so proof of Turing Completeness is always a challenge.

A related pursuit among programming language enthusiasts is the writing of obfuscated code.

History

The generally accepted dawn of the Esoteric Programming Language was in 1972, with the creation of INTERCAL by James Lyons and Don Wood, with the stated intention of being unlike any other programming language the authors were familiar with. Utilizing a counterintuitive set of operations and a character set full of awkward constructions, Intercal is a classic example of what are now known as Write-only Imperative, or sometimes Despotic programming languages.

The next notable event in the field was more than twenty years later, when Urban Müller created the now famous Brainfuck, which with only eight recognized characters is considered the canonical example of a Turing tarpit. Along with Befunge, Brainfuck is now one of the most well-supported esoteric programming languages, and it is no surprise that both are highly valued as they were both the first of their respective kinds and still the most elegant.

Esoteric Programming Terms

Turing Tarpit

A programming language with arbitrarily few commands. These include Brainfuck (8 commands, all with 0 operands), OISC (1 command, 3 or 4 operands), and Thue (1 command, 2 operands).

Language Paradigm

The paradigm of a language can fall into a number of categories, and these categories are used to get a general understanding of the way that a specific language operates. These include Imperative/Despotic languages such as Brainfuck, in which instructions describe how to change data; Functional languages such as Unlambda, in which data and code are more or less interchangeable and excecution is the repeated aplication of functions to the results of other functions; and Rewriting languages such as Thue, in which transformation functions are applied to an initial state.

Deterministic Language

A deterministic language is one in which it can always be predicted based on the state of a program what the next state will be. Most languages are deterministic, as nondeterministic languages such as Java2k often give unreliable results, and getting even trivial programs to have a reliable output is often a monumental task.

Despotic Language

A despotic language is a term coined for a Turing Tarpit with a Stateful Encoding, meaning a language in which commands are used to select from a finite range of operations and apply these operations to the current state of the program. Examples include ReMorse and Whirl, and some have suggested that even INTERCAL is a Despotic language. See also Turning Tarpit

Turning Tarpit

A highly minimalist Despotic Language in which the only way to select an operation is by moving along a list of Stateful Encodings. This was coined as the result of a Freudian slip while discussing the despotic language Whirl.

Stateful Encoding

A system of encoding programs such that each substring of the encoding is an instruction to locate the next instruction in a list. An example based on ReMorse would be: . Select Next Operation in list - Perform Operation With the list of operations either standard (as in ReMorse) or dynamic (as in ReMorse4ever)



Example languages

The canonical esoterical languages are probably Intercal, Brainfuck, and Befunge.

Category:Esoteric programming languages provides an automated exhaustive list.

List of esoteric programming languages is a manually-made list.

The esoteric languages mailing list

The esotering languages mailing list, lang@esoteric.sange.fi, is a good place to discuss esoteric languages, announce your own creations or just stay updated on what other people are working on. To subscribe, send a mail with the text subscribe lang to listar@esoteric.sange.fi