A fun interpreter inspired by Brainfuck made in java
Captl works by using letters and symbols as tokens. It also uses Capitalisation for more tokens. It uses a simple byte memory system for operations like Brainfuck.
The token syntax is as Simple as in Brainfuck, but some tokens have arguments
H
- Highers the current byte by 1h
- Lowers the current byte by 1p
- Prints the current byte as ascii characterP
- Prints all bytes in memory as ascii characterN
- Switches to the next memory celln
- Switches to the previous memory celli
- Takes the next char from input and puts into the current cellI
- Takes the next line from input and puts into the memorye
- Empties the byte bufferE
- Empties the current memory cellV[variable identifier]
- V saves the current memory cell into the given variable;
- Starts or ends a commentA<number/variable>
- Adds the following number to the current cellD<number/variable>
- Subtracts the following number from the celld"<string>"
- Decodes a String into memoryr<number/variable><token>
- Repeats the token times the given numberR<number/variable>
- Sets the recursion_number pointer to the given number[
- Enters the while(block != recursion number) loop]
- jumps back to[
if block != recursion_number
Variables are identified by special characters such as !"§$%&/)=?*+~'#-_.:,;<>|^°
which can only consist of only 1
of predefined characters
Captl can be accessed via the command line like this.
java -jar Captl.jar -f file.captl
- Executes from the given filejava -jar Captl.jar -i
- Opens the live interpreting consolejava -jar Captl.jar <Captl Code>
Directly executes the given code from command line