Return to Statement


Program Loop Example 3

This example demonstrates that modifying the end value once a do loop has started has no impact.

$$
$$ Declarations
$$
NUMBER/N
N=5
$$
$$ Do Statements
$$
DO/L10:,I,1,N
N=N-1
PRINT/I,N
L10: $$ end do I
HALT/

This example produces the following output:

    1.0000,4.0000
2.0000,3.0000
3.0000,2.0000
4.0000,1.0000
5.0000,.0000