DO_LOOP, EXIT_LOOP, END_LOOP action
Related pages:
[FOR _ctrlVar [RANGE struct | = lBoundExpr TO uBoundExpr] ] DO_LOOP ...; actions 1 [EXIT_LOOP [expression]] ...; actions 2 [EXIT_LOOP [expression]] ...; akctions 3 END_LOOP
expression | in | Expression of Boolean type. |
INT _i INT _uBound _uBound := 10 FOR _i=2 TO _uBound DO_LOOP _uBound := _uBound + 1 ; value change has no effect on the number of iterations END_LOOP ; value of the variable _i is 11
INT _i RECORD (SD.ArchVal) _struct REDIM _struct[10] FOR _i RANGE _struct DO_LOOP REDIM _struct[2] ; value change has no effect on the number of iterations END_LOOP ; value of the variable _i is 11
INT _i _i := 1 DO_LOOP EXIT_LOOP _i = 10 _i := _i + 1 END_LOOP
INT _i _i := 1DO_LOOP IF _i = 10 THEN EXIT_LOOP ENDIF _i := _i + 1 END_LOOP
For example:
INT _i _i := 1 IF Sec = 1 THEN DO_LOOP ENDIF EXIT_LOOP _i = 10 _i := _i + 1 END_LOOP
INT _i _i := 1 DO_LOOP IF _i = 10 THEN EXIT_LOOP ENDIF _i := _i + 1 IF Sec = 1 THEN _i := _i + 1 END_LOOP ELSE END_LOOP ENDIF
Related pages:
Pridať komentár