On the Subject of Markscript
Turing complete on the inside, wacky stripes on the outside.
This module is a computer, which itself consists of a screen, a red power button, and a keyboard.
☺ key is pressed, it will give you a task which will be a description of a program you must write.
Executing a program to complete the task provided solves the module. This module will not strike.
While the program is being written, pressing the power button will execute the program. If the program is being executed while it’s pressed, the program will halt instead.
Almost all keyboard keys, including the one shaped like a Z in Tetris, will simply append the character shown on the key to the current line. The exceptions are listed below.
☺: Shows/hides the task. All other controls don’t work while shown.
←: Removes the final character from the current line. Note that this does not work if the character you are attempting to remove is a
▼: Moves the cursor to the previous or next line, respectively.
Your real-life keyboard can also be used to type. Letters, space, backspace, and arrow keys always work as expected. Enter and numbers work normally so long as Shift is not held. The table below shows what real-life keys are changed to when Shift is held. Keep NumLock in mind when using the real-life keyboard.
The program will be written in a programming language called, unsurprisingly, Markscript.
The complete documentation of which is provided below.
All variables presented in the task will be automatically given values before the program is run.
The module will solve when the correct output is returned five times in a row.
If an incorrect output is returned or the module attempts to execute a line with a syntax error, the screen will display the problem and the program will halt.
☺ to return to the program while in this state.