if..then..else used to process one statements or one block statements, depending value was tested.
sintax : 1
if<expressin> then <statements>;
or,
sintax : 2
if<expressin> then <statements1>else <statements2>;
<expressin>is logic expression. sintax 1, if will test his right <expression>. if <expression> value true, then statement or block statement in his right will be process. if <expression> value false, then statement or block statement in his right will not be process.
sintax 2 : if will test his <expression>. if <expression> value true, then statement or block statement in his right will be process. if <expression> value false, then statement or block statement in else right will be process.
as a examples :
//examples 1
<>
No comments:
Post a Comment