Sigq

From Esolang
Jump to navigation Jump to search

Created by User:TheSpiderNinjas

Stuff

!
True

?
False

!?!
Binary, ! for 1 and ? for 0

1
Variable

{7}
Number, only works as a value

0 = !?!
Set a var to a value ^= for specifically bool #= for specifically int

0? [ ]
If the value is true run the block of code

0? < >
While the value is true run the loop

0? [ ]
If the value is true jump to specified label

0::1 [ ]
If the values are equal run the block of code

0::1 < >
While the values are equal

0::1 @label
If the values are equal jump to specified label

@label
Jump to specified label

label:
Declare label

0~
Halt program if value is true

~
Unconditional Halt

0. (int)
Print value as ASCII

0. (bool)
Print value as 0 / 1

0$ (int)
Accept input as ASCII

0$ (bool)
Accept input as 0 / 1

^0
Convert value to bool

#0
Convert value to int

0!
NOT, NOTs a value

0&1
AND, ANDs two values

0|1
OR, ORs two values 

{ !?! }
Value, just a literal

[ ... ]
Block of code, Runs the code inside

( ... )
Parentheses, order of operations

< ... >
Loop, Like the block of code but loops forever

;Comment
Comment, Self explanatory

Examples

Truth Machine

^0$ ;Get input (0/1)
0? <0.> ;If 1 print input forever (1)
0. ;Print input

Cat program

<0$ 0.> ;Loop forever between getting input and outputting it 

Hello World

{72}. {101}. {108}. {108}. {111}. {44}. {32}. {87}. {111}. {114}. {108}. {100}. {33}.

Computational Class

Probably turing complete idk ¯\_(ツ)_/¯