I started this project as a joke, but it turned out to be more than this.
The language has a interpreter written in C++, and also a C++ transpiler.
The syntax is weird on purpose, but also very easy to read for non programmers, easier than Python.
The language features variables, input/output, arithmetics, if statements, for loops and functions.
I also created a Web Assembly frontend for the language, and a small documentation.
- Identifiers must be capitalized
- Numbers can be written only in letters, 57❌ fifty-seven✔️
- Can't use numbers outside the range [zero, ninety-nine]
- Indentation must be a multiple of 4
let X
(defaults as 0)
let Y be ten
let Z be Y
say X
say two
say space
(evaluates as ' ')
say line
(evaluates as '\n')
read X
add one to X
subtract one from X
multiply X by two
divide X by two
if X is odd
if X is even
if X equals nine
if X not-equals nine
if X is less-than nine
if X is greater-than nine
if X is less-equal nine
if X is greater-equal nine
if X is divisible-by nine
if X is divisible-by nine
say X
else
say zero
for every N from five to Z
for every M from Z to N
code//
function F
say one
call F
let A be zero
let B be one
let N be one
function F
let C be A
add B to C
let A be B
let B be C
say C
say space
add one to N
if N less-equal ten
call F
call F
Output:
1 2 3 5 8 13 21 34 55 89
- C++ 11 compiler
- Emscripten for Web Assembly
- In the root directory
emcc main.cpp --bind -o public/main.js -s NO_DISABLE_EXCEPTION_CATCHING
- Serve
public/index.html