π
Jump to navigation
Jump to search
π is an interpreted esoteric programming language made by User:Kloodi, Written in Python.
It is based on using emojis similar to calling functions in a normal programming language.
Values
You can use the following structures to represent values.
Structure | Value |
---|---|
"string"
|
A string with the value of string . If the length of the string is greater than 0, It is considered true.
|
number
|
A number with the value of number . If the number is greater than 0, It is considered true.
|
Emojis
You can use the following emojis to do specific actions.
Emoji | Action |
---|---|
π/value\
|
Print value .
|
β
|
Ask the user for input, And return the string. |
π³
|
Halt the program. |
π©/name\/value\
|
Store value to the variable called name .
|
π¨/name\
|
Get the value in the variable called name and return it.
|
β/left\/right\
|
Return the sum of left and right .
|
β/left\/right\
|
Return the difference of left and right .
|
β/left\/right\
|
Return the product of left and right .
|
β/left\/right\
|
Return the quotient of left and right .
|
Special Commands
These are commands that don't follow the same structure as the emojis.
Command | Action |
---|---|
{code}expr
|
Loop code while expr is true.
|
Examples
Hello, World!
This example prints the phrase "Hello, World!"
.
π/"Hello, World!"\
Cat Program
This example prints the same string that the user inputs.
π/β\
Truth Machine
This example prints 0 once if the input is 0,
And 1 forever if the input is 1.
π©/"x"\/β\{π/1\}π¨/"x"\π/0\
Interpreter
If π appears as ?? in your terminal, Don't worry. It still represents π.