Varia

From Esolang
Jump to navigation Jump to search

Varia is an equation-based esolang created by User:Ϫ.

Commands

Anything after the equals sign is irrelevant to the command, but it will not parse the line if it is not correct.

A= Sets variable A to the user input.
Log(A)= Sets variable A to 0.
A+B= Stores A into B.
[X]+B= Stores value X into B. (you do not write the brackets)
A(B+C)= Sets A to the result of B+C.
A(B-C), A(B*C), A(B/C), A(B^C)= Like A(B+C)=, but for different operations.
A^[X]= Outputs A and sets A to X at the same time.
A/[X]= Sets A to true if X is even or false if X is odd.
A^B, A/B Like A^X and A/X, but for the variables.
Sin(A)= Skips the next line if A is false, but runs it if A is true.
Cos(A)= Like Sin(A), but flipped.
Sin([X])= Sets jump point X
Cos([X])= Goes to jump point X

Computational class

The language has access to all of the features required to implement counter machines. If the restriction for the line equation being correct was not in place, then it is Turing complete. With the restriction in place, it's not clear, but still likely Turing complete since it is implied that the list of equations is evaluated separately from execution.

Programs

Truth Machine

A=4
A/A=1
Sin(7)=0.65698659871
A+B=7
B^0=1
Sin(A)=-0.7568024953
Cos(7)=0.75390225434