conditionals examples

This commit is contained in:
Romain Paquet 2024-03-08 17:38:53 +01:00
parent 511be952aa
commit 8e3994f582
3 changed files with 20 additions and 0 deletions

6
examples/and_or_not.lila Normal file
View file

@ -0,0 +1,6 @@
fn main() {
yes = true;
no = !yes;
impossible = yes && no;
always = yes || no;
}

View file

@ -0,0 +1,8 @@
fn main() {
x = 0;
if true {
set x = 42;
} else {
set x = 1337;
};
}

View file

@ -0,0 +1,6 @@
fn main() {
x = 0;
if true {
set x = 42;
};
}