LOLCODE

SL83

Veteran XV
HAI
CAN HAS STDIO?
PLZ OPEN FILE "LOLCATS.TXT"?
AWSUM THX
VISIBLE FILE
O NOES
INVISIBLE "ERROR!"
KTHXBYE


HAI
CAN HAS STDIO?
I HAS A VAR
IM IN YR LOOP
UP VAR!!1
IZ VAR BIGGER THAN 10? KTHX
VISIBLE VAR
IM OUTTA YR LOOP
KTHXBYE

HAI
CAN HAS STDIO?
IM IN YR LOOP UPPIN YR VAR TIL BOTHSAEM VAR AN 10
VISIBLE SUM OF VAR AN 1
IM OUTTA YR LOOP
KTHXBYE
 
Whitespace is an esoteric programming language developed by Edwin Brady and Chris Morris at the University of Durham. It was released on 1 April 2003 (April Fool's Day). Its name is a reference to so-called whitespace character codes in text files. When a text file is printed, whitespace codes move the cursor ahead without making any mark on the page thus leaving a white space. They include the codes for space, tab, and line feed (newlines). Unlike most programming languages, which ignore or assign little meaning to most whitespace characters, the Whitespace interpreter ignores any non-whitespace characters. Only spaces, tabs and linefeeds have meaning. An interesting consequence of this property is that a Whitespace program can easily be contained within the whitespace characters of a program written in another language, making the text a polyglot.
 
Back
Top