![Free-eBooks.net](/resources/img/logo-nfe.png)
![All New Design](/resources/img/allnew.png)
This is an excellent substitute to the control statement like IF/THEN/ELSE
of BASIC language. It is denoted by the combinational characters ?: and
follows the usage with the following format/syntax :
which indicates that if the test expression is true then the transfer value
for storage into the value variable is expression1 and if the test
expression is false the transfer value becomes the expression2.
In the above example grade refers to the value variable, total>40 is the
test expression, ‘P’ is the expression1 and ‘F’ is the expression2. The ?
character follows the true condition and : follows the false condition.