Denso RC5 Specifications Page 268

  • Download
  • Add to my manuals
  • Print
  • Page
    / 692
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 267
11-18
IF-THEN-ELSE (Statement)[Conforms to SLIM]
Function
Executes a conditional decision of a logical expression.
Format
IF <Conditional expression> THEN {<Statement>|<Label name>} [ELSE
{<Statement>|<Label name>}]
Explanation
This statement controls the execution of a program depending on the condition
of <Conditional expression>.
If <Conditional expression> is true (except for 0), then the latter section of
THEN is executed. If the <Conditional expression> is false (0), then the latter
section of ELSE is executed.
Related Terms
IF-END IF
Example
IF l0 = 0 THEN STOP ELSE GOSUB *samp1
'If i1 is 0, control stops program execution. If il is
'another value, control calls the subroutine with a
'label name of *sampl.
il = il + 1 'il is added.
END 'Defines the program end.
*sampl: 'Defines the subroutine label.
i0 =0 'Substitute 0 for i0.
RETURN 'Returns to the calling program.
Page view 267
1 2 ... 263 264 265 266 267 268 269 270 271 272 273 ... 691 692

Comments to this Manuals

No comments