Conditions
if statement
if statementExample
with console from std:io
if(a < 10)
console.out("a is smaller than 10")
else if(a is 11)
console.out("a is 11")
else if(a > 11 and a < 21)
console.out("a is greater than 11 and smaller than 21")
else
console.out("a is " + a)
endExample
with console from std:io
if(condition)
console.out("yes")
else if(otherCondition)
console.out("maybe")
else if(otherOtherCondition)
console.out("maybe not")
else
console.out("no")
endmatch block
match blockExample
Example
Last updated