Documentation

Warning: The interpreter is still in beta and may have bugs. If you need help with code or find a bug, please report it on the Forum Topic.

Master List of Commands

Comments are newlines that starting with #.

Control Structures

Functions

Conditions

Conditions use the following syntax: <value> <operator> <value>

Operators include: `=`, `!=`, `<`, and `>`. Conditions can be combined using `and`, e.g., {varname} = 1 and 12 > {myvar}.

Examples

  1. Variable Assignment and Output:
        set x to 10
        out {x}
  2. Arithmetic Operations:
        set a to 5
        set b to 3
        add {a} {b} as c
        out {c}
  3. While Loop Example:
        set counter to 0
        while {counter} < 5
          add {counter} 1 as counter
          out {counter}
        end
  4. If Statement Example:
        set num to 7
        if {num} > 5
          out "Number is greater than 5"
        end
  5. Date Function Example:
        date year as currentYear
        out {currentYear}
  6. Array Example:
        array a b c d as alphabet
        out The 3rd letter of the alphabet is {alphabet:3}!
  7. Function Example:
        function greet
          out "Hello, World!"
        end
    
        call greet
  8. Function with Conditional Logic Example:
        set x to 1
    
        function greet
          if {x} = 0
            out "Hello, World! 1"
          end
          if {x} = 1
            out "Hello, World! 2"
          end
        end
    
        call greet
        set x to 0
        call greet

Expressions