Jump to content

Conditional structures: Difference between revisions

(added Ol)
Line 2,916:
Print "Bottom"
}
}
CheckIt 100
CheckIt 0
CheckIt -100
 
Module CheckIt {
Read a
\\ using end if without blocks
If a>1 then
Print "Top"
else.if a>=-4 then
Print "Middle"
else
Print "Bottom"
End If
}
CheckIt 100
CheckIt 0
CheckIt -100
 
Module CheckIt {
Read a
\\ without use of END IF in one line
If a>1 then Print "Top" else.if a>=-4 then Print "Middle" else Print "Bottom"
}
CheckIt 100
Anonymous user
Cookies help us deliver our services. By using our services, you agree to our use of cookies.