Test a for() loop as well.
All checks were successful
The build was successful.

This commit is contained in:
2019-04-17 11:07:53 +02:00
parent b668d0a897
commit 9d97eb228a
2 changed files with 71 additions and 0 deletions

20
tests/loop_for_test.aer Normal file
View File

@@ -0,0 +1,20 @@
class Program {
public void main() {
int $c = 4;
for(int $a = 0; $a < 10; $a++) {
for(int $b = 0; $b < 10; $b++) {
int $c = 2;
if($b == 2) {
continue;
}
if($b == 6) {
break;
}
print("Hello variables: $a $b $c\n");
}
}
print("Variable \$c: $c\n");
}
}