Turina

From Esolang
Jump to navigation Jump to search
This article is not detailed enough and needs to be expanded. Please help us by adding some more information.

Turina is an esolang I cooked up which relies on the concept of a Turing Machine.

Commands
Instruction Meaning
i.state1.state2 If state1 is observed, change it to state2. (.out makes it output and change to 0. Also, the code .any can be used.)
f.index.b Flips the indexed value's bth bit. If no b-value is specified, use 1 as the bit (a.k.a. the first bit) unless there is an l.l instruction at the top of the code.
j.index Jumps to the indexed value.
index1.index2.index3.gate Applies the gate to the two indexed values and sets index3 to that value.
t.tape.index1 Sets the tape and starts at the indexed value.
l.l Makes the default b-value the last bit instead of the first.

In addition, g.l goes to line number l. It ends when any instruction in the loop cannot be executed.
I think that any FlipJump program could be converted to this, and so I also think it is Turing-complete, but if it isn't, let me know.

Example programs

Hello world program

t.!72,101,108,108,111,44,32,119,111,114,108,100!.0
i.>0.outa
g.2
$ Comments exist. Also, outa just means output in ASCII. $

Looping counter program (decimal, not unary)

i.any.inc $ increment, decrement is dec, mul.x div.x mod.x etc... $
i.any.out
g.1