Syntax should be like the one discussed in class.
The only addition is the print-statement in the last line.
You can use ?VAR to print a variable, where VAR is the variable in question.
x0 := x1 + 0;
x2 := x2 + 1;
x2 := x2 + 1;
WHILE x2 != 0 DO
x0 := x0 + 1;
x2 := x2 - 1;
END;
?x0;
- Clone the project
- Execute:
cargo r <filename>