Some people would say that learning to program is hard and excruciating. Maybe these people are not born to be developers because programming languages are supposed to be easy to use and learn. However, some people think that there are not enough programming languages that challenge people, so they decided to make some weird, funny, frustrating languages. Some of them are completely meaningless and goes against all principles. The fact is that programming is fun for these people, so why wouldn’t they play with a code? So, let’s take a look at some of the weirdest and craziest programming languages.
The psychological secret behind funny coding languages
Did you know that there is scientific proof that humor increase creativity? Laughter and humor are very complex cognitive functions that involve the entire brain. While the left brain hemisphere “sets up” the joke, the right one helps “getting” the joke.
During research at Northwestern University, one group of people watched a comedy, while the other watched a horror movie (The Shining). After that, both groups had to solve a puzzle. Can you guess which group was more creative?
The situation is similar with sarcasm. It can increase creativity, but only if it’s used in a safe place, when trust between people exists.
Programmers have a specific type of humor. These weird programming languages boost creativity not only of people who create them but of those who read or use them. So, if you have an idea of how to create some funny coding language, go for it! The more you complain, the less creative you are, and the more humor you use, the more creative you get.
1. LOLCODE 😹
As you can guess, this language is made up of lolspeak, the “language” used by lolcats. All words are capitalized and meme-fied, so you can almost imagine a cat using it! LOLCODE was designed by Adam Lindsay in 2007, a researcher at Lancaster University’s Computing Department. Although you won’t be able to use LOLCODE for anything more than reading a file or writing text to the console, the hilarity, and charm of the language make up for its disadvantages. Take a look at the ‘Hello World!’ code below. You will see how adorable it is.
CAN HAS STDIO?
I HAS A VAR
IM IN YR LOOP
IZ VAR BIGGER THAN 10? KTHX
IM OUTTA YR LOOP
How would you like to call yourself a rockstar programmer? 🎸 It sounds great, and because of this joke programming language, it’s possible to become one. Rockstar is designed for creating computer programs that are also song lyrics and one of the reasons that Dylan Beattie made it is to stop recruiters and managers from referring to people as “rockstar programmers”. Now you can have a sticker on their laptop saying “CERTIFIED ROCKSTAR DEVELOPER”. That’s rock’n’roll! Moreover, comments in Rockstar programs is strongly discouraged because it’s up to the audience to find their own meaning. 👀
Here is an example: inspired by here-document Rockstar supports a unique language feature known as poetic literals. It allows you to simultaneously initialize a variable and express your innermost angst.
- My heart is true – initialises the variable my heart with the Boolean value true
- Tommy is nobody – initialises the variable Tommy with the value null using the nobody alias
3. TrumpScript 🇺🇸
It started as a joke that this is the programming language Trump would approve of – just as he is making America great again, owners hope that this language will make programming great again. Although development on this project has stopped, owners want to send a strong message. They think that this joke isn’t funny anymore and want to make an influence on people to actually do something about serious problems in the world. For example, you can make a donation to charity instead of spending your time beating the “Trump is ridiculous” meme to death.
Here are several convenient features that TrumpScript uses:
- No floating point numbers, only integers. America never does anything halfway.
- All numbers must be strictly greater than 1 million. The small stuff is inconsequential to us.
- There are no import statements allowed. All code has to be home-grown and American made.
- Instead of True and False, we have the keywords fact and lie.
- Only the most popular English words, Trump’s favorite words, and current politician names can be used as variable names.
- Error messages are mostly quotes directly taken from Trump himself.
This language is made to play with your mind – it is notoriously difficult to program in. Brainf*ck is not intended for practical use, but to challenge and amuse programmers. This is a minimalistic language that uses only eight commands and an instruction pointer, each made up of a single character. Creator Urban Müller was still a physics student when he made this language (in 1993). Since then this obscure language reached almost a cult following. Let’s see how a sample of the headache-inducing code that will print out “Hello world!” looks like:
This interesting programming language uses the source code that looks exactly like a Shakespeare play. The characters in the play are variables and constants are decided by positive or negative nouns. For example, if Hamlet is a negative value, you can put him and another character on the stage and let that character insult Hamlet. You can add input and output by having someone tell a character to listen to their heart and speak their mind. You can see now why this program is so different than others – programming language includes characters, titles, scenes, acts, enter, and exit directives, making it look much like the plays of Shakespeare.
A piece of code in Shakespeare is broken into Acts which contain Scenes in which characters (variables) interact:
Act I: Hamlet’s insults and flattery.
Scene I: The insulting of Romeo.
Most programming languages ignore whitespace characters, so Edwin Brady and Chris Morris created this language as an April Fools’ joke. Whitespace uses them as commands, ignoring non-whitespace characters instead. It understands only spaces, tabs and new lines. Here is an example (spaces are marked with an S and tabs with a T):
S S S T S S T S S S
S S S S S T T S S T S T
S S S S S T T S T T S S
S S S S S T T S T T S S
S S S S S T T S T T T T
S S S S S T S T T S S
S S S S S T S S S S S
This interesting programming language uses MIDI files as source code: the pattern of notes determines commands. Programmer-musicians will love Velato because they can compose a musical piece that fills the constraints necessary to compile to a working Velato program. Each song has a secret message and the program determines when it’s compiled as Velato. So, let’s make some music and code at the same time!
8. Chicken 🐔
As crazy as this may sound, it’s the truth – this language allows only one world, and this word is “chicken”! Swedish programmer and creator of this language Torbjörn Söderstedt was inspired after hearing Doug Zongker’s parody of scientific speeches to make Chicken programming language. To write the whole code would take half the page and consist of nothing but the word ‘chicken’, so here is just a piece of code:
chicken chicken chicken chicken chicken chicken chicken chicken chicken chicken chicken
chicken chicken chicken chicken chicken chicken
Piet is a so-called esoteric programming language, and it’s very arty! Programs are bitmaps that look like abstract paintings, and the basic building block for Piet programs is the color block. However, the colors are not important, but the transitions – transitions in hue and darkness form the code. It definitely goes into a group of weird coding languages!
Piet is created by David Morgan-Mar, but named after the Dutch painter Piet Mondrian. He had increasingly abstract style – he reached a point where his artistic vocabulary was reduced to simple geometric elements. Watch the video and find out more about this funny coding language:
This unique, two-dimensional programming language was created by Chris Pressey in 1993 for the Amiga. Your code is placed on play field with a fixed size, and as its instruction pointer moves along, it pushes or pops values to or from the stack, or takes an action on the values at the top of the stack,
There is no comment syntax in Befunge. If you want to embed documentation in the code, the programmer simply routes the control flow around the “comment” area, so that the text in that area is never executed. This weird programming language will definitely blow your mind, especially because it’s one of the oldest.
This is how you write “Hello, world!” in Befunge:
- 0″!dlroW ,olleH”>:#,_@
Here are some commands used in Befunge:
- — * / % Add, subtract, multiply, divide or perform modulo division of two top stack values. The bottom element is used as first operand, the top one — as the second
- ! Logical NOT
- ` Greater Than
- < > ^ v Make instruction pointer face left, right, up or down
- ? Make instruction pointer face random direction
- _ | Horizontal/vertical IF. Both commands pop the topmost element of the stack; if it equals 0, they perform > v commands. Otherwise, they perform < ^ commands
- ” Toggle string mode. In string mode, each character encountered by the instruction pointer is pushed on the stack (as its ASCII-code)
- : Duplicate top stack value
The fact is that some of these languages made programmers totally confused, but some of these ideas influence the entire industry. There are hundreds of funny coding languages like those on our list. Some of them are made just for fun, some are meant to be just different from others, but there are few of them that want to send a strong message to the audience. Which weird programming language do you find the most interesting? Let us know!