Alex

From Esolang
Jump to: navigation, search

Alex, is an esoteric programming language, with stack-based memory like in brainfuck, buts here strange syntax, and all command need be ended with: " - Alex.". Idea of this language was invented by Ronald Houkens.

Examples

Hello, World!

You: It's comment.
You: Hello World on Alex

Say H - Alex.
Say e - Alex.
Say l - Alex.
Say l - Alex.
Say o - Alex.
Say , - Alex.
Say Space - Alex.
Say W - Alex.
Say o - Alex.
Say r - Alex.
Say l - Alex.
Say d - Alex.
Say ! - Alex.
Say LineFeed - Alex.

Counts from 5 to 0

Set A1 5 - Alex.

Label A - Alex.
Put A1 - Alex.
Decrement A1 - Alex.
Say LineFeed - Alex.
IfNotZero A1 A - Alex.

Truth-machine

You: Truth-machine by SLNETAIGA

Set A1 0 - Alex.
Set A2 1 - Alex.

Get A3 - Alex.
IfEquals A3 A1 z - Alex.
IfEquals A3 A2 o - Alex.
End - Alex.

Label o - Alex.
Say 1 - Alex.
GoTo o - Alex.

Label z - Alex.
Say 0 - Alex.
End - Alex.


Translate to brainfuck

Brainfuck Alex
+ Increment Acell id - Alex.
- Decrement Acell id - Alex.
> No this. Just specify cell id
< No this. Just specify cell id
. Puts Acell id - Alex.
, Gets Acell id - Alex.
[ label A - Alex.
] IfNotZero Acell id A - Alex.

External resources