Top 20 Strangest Programming Languages (10-6)

10. Whenever

Don’t you love it when, as a programmer, you tell the computer exactly what to do and when, and it just obeys your every command within milliseconds? Well, the Whenever language doesn’t.

Whenever is a lot like your pet cat. It has no sense of urgency, and does what it wants, and when it wants. Lines of code aren’t executed sequentially. They are treated more like “to-do” lists, which the language interpreter may tackle in any order it likes.

The stated atomic design principles are:

  • Program code lines will always be executed, eventually (unless we decide we don’t want them to be), but the order in which they are executed need not bear any resemblance to the order in which they are specified.
  • Variables? We don’t even have flow control, we don’t need no steenking variables!
  • Data structures? You have got to be kidding.

9. Brainfuck

Brainfuck is an esoteric programming language that will, true to its name, fuck with your brain. It was created in 1993 by Urban Müller, and is notable for its extreme minimalism. Brainfuck can be implemented by a really small compiler. The language uses only eight commands and an instruction pointer, each made up of a single character.

The following program outputs “Hello World!”:

++++++++++[>+++++++>++++++++++>+++<<<-]>++.>+.+++++++ ..+++.>++.<<+++++++++++++++.>.+++.------.--------.>+.

8. LOLCODE

LOLCODE is designed using the language of lolcats, also known as lolspeak. For example “HAI” is used to introduce the program and “KTHXBYE” is used for termination.

The language was created in 2007 by Adam Lindsay, researcher at the Computing Department of Lancaster University. The following is a “Hello World” program in LOLCODE

1
2
3
4
HAI
CAN HAS STDIO?
VISIBLE "Hello World!"
KTHXBYE

 

7. Shakespeare

Even if Schwarzenneger style heavy action flicks isn’t your cup of tea, don’t worry. Shakespeare’s got your back. As the great poet and playwright William Shakespeare once penned, “All the world’s a program, and all the men and women merely variables.” Ok, maybe that’s not exactly what he wrote, but that’s a pretty accurate summary of the Shakespeare Programming Language.

The design goal of Shakespeare was to make the source code resemble Shakespeare plays. The characters in the play are variables. If you want to assign a character, let’s say Hamlet, a negative value, you put him and another character on the stage and let that character insult Hamlet.

Input and output is done by having someone tell a character to listen to their heart and speak their mind. The language contains conditionals, where characters ask each other questions, and jumps, where they decide to go to a specific act or scene.

Below is a sample “Hello World” program.

The Infamous Hello World Program.

Romeo, a young man with a remarkable patience.
Juliet, a likewise young woman of remarkable grace.
Ophelia, a remarkable woman much in dispute with Hamlet.
Hamlet, the flatterer of Andersen Insulting A/S.


                    Act I: Hamlet's insults and flattery.

                    Scene I: The insulting of Romeo.

[Enter Hamlet and Romeo]

Hamlet:
 You lying stupid fatherless big smelly half-witted coward!
 You are as stupid as the difference between a handsome rich brave
 hero and thyself! Speak your mind!

 You are as brave as the sum of your fat little stuffed misused dusty
 old rotten codpiece and a beautiful fair warm peaceful sunny summer's
 day. You are as healthy as the difference between the sum of the
 sweetest reddest rose and my father and yourself! Speak your mind!

 You are as cowardly as the sum of yourself and the difference
 between a big mighty proud kingdom and a horse. Speak your mind.

 Speak your mind!

[Exit Romeo]

                    Scene II: The praising of Juliet.

[Enter Juliet]

Hamlet:
 Thou art as sweet as the sum of the sum of Romeo and his horse and his
 black cat! Speak thy mind!

[Exit Juliet]

                    Scene III: The praising of Ophelia.

[Enter Ophelia]

Hamlet:
 Thou art as lovely as the product of a large rural town and my amazing
 bottomless embroidered purse. Speak thy mind!

 Thou art as loving as the product of the bluest clearest sweetest sky
 and the sum of a squirrel and a white horse. Thou art as beautiful as
 the difference between Juliet and thyself. Speak thy mind!

[Exeunt Ophelia and Hamlet]


                    Act II: Behind Hamlet's back.

                    Scene I: Romeo and Juliet's conversation.

[Enter Romeo and Juliet]

Romeo:
 Speak your mind. You are as worried as the sum of yourself and the
 difference between my small smooth hamster and my nose. Speak your
 mind!

Juliet:
 Speak YOUR mind! You are as bad as Hamlet! You are as small as the
 difference between the square of the difference between my little pony
 and your big hairy hound and the cube of your sorry little
 codpiece. Speak your mind!

[Exit Romeo]

                    Scene II: Juliet and Ophelia's conversation.

[Enter Ophelia]

Juliet:
 Thou art as good as the quotient between Romeo and the sum of a small
 furry animal and a leech. Speak your mind!

Ophelia:
 Thou art as disgusting as the quotient between Romeo and twice the
 difference between a mistletoe and an oozing infected blister! Speak
 your mind!

[Exeunt]

6. Befunge

The goal of Chris Pressey, creator of the Befunge, was simple, and pure evil : design a programming language that is as difficult to compile as possible. Befunge accomplishes this by its two main features:

  • self-modifying code – instructions can write new instructions into the playfield
  •  multi dimensional code -the same instruction can be executed in four different contexts(left-to-right, right-to-left, upward or downward).

Programs are arranged on a two-dimensional grid. “Arrow” instructions direct the control flow to the left, right, up or down, and loops are constructed by sending the control flow in a cycle.

The language was first introduced in 1993, and over the years some people have actually successfully managed to create compilers for it. Here’s a sample “Hello World”program in Befunge:

Befunge - Top 20 Strangest Programming Languages - Hello World Program

Previous Page                                                                             Next Page

Leave a Reply