Column

From Esolang
Jump to navigation Jump to search

Column is an esoteric programming language developed by Dominicentek. It's code is executed column by column in a text file, rather than line by line like in a typical programming language.

Instructions

Column instructions
Instruction Syntax Description
var <string : variable name> <value : var value> Defines a variable
print <value : printed value> Prints a value to console
user <string : variable name> Defines a variable with user input as a string
if <value : left hand value> <operator : (= != < > <= >=)> <value : right hand value> If condition is true, execute a code block
else If the above IF instruction returns false, execute this code block instead
function <string : function name> Defines a function
call <string : function name> Calls a function
label <string : label name> Defines a label
goto <string : label name> Goes to a label
add <string : variable name> <value : value> Adds a value to a variable
sub <string : variable name> <value : value> Subtracts a value from a variable
mul <string : variable name> <value : value> Multiplies a value in a variable
div <string : variable name> <value : value> Divides a value in a variable
mod <string : variable name> <value : value> Modules (gets division reminder) a value in a variable
toint <string : variable name> Converts a string variable into an integer
tostr <string : variable name> Converts an integer variable into a string
end Ends a code block, if not in a code block, it exits the program
exit Exits program

Argument types

String argument type can be anything. Terminated with a space.
Value argument type, if its a number, its an constant integer. If its a string wrapped in double quotes are strings that can contain spaces. Otherwise it's a variable.

Examples

Hello World

p
r
i
n
t

"
H
e
l
l
o

W
o
r
l
d
!
"

Truth Machine

utipeeelpg
sofrxnlaro
ei iidsbit
rnint eeno
 tnt   lt
i p      l
niu0   l1o
pnt    o o
up     o p
tu=    p
 t
  0

Fizz Buzz

utvlavvmmipeipeiipeepige
soaadaaoofrnfrnffrnnrfon
eirbdrrdd id id  iddi td
rn e     tn fn tfn  nao 
 talatftfht it hit  tm  
i m mhihir  v  rv    op 
nioporvrve" e" eea  "ur 
pnurueeeeeF  B e m  \ni 
upnine e  i =u  !o  ntn 
tutnt a 5=z  z !=u  " t 
 t t am3  z 0z = n   <  
  0 1mo  0"  "  0t      
     ou        0     i  
     un              n  
     nt              p  
     t               u  
                     t  

Interpreter

Download

See also