Previous Next Chapter

Results.rexx

The TRACE instruction activates ARexx's error checking feature.

Program 6. Results.rexx

/*Demonstrate "results" tracing*/
TRACE results
sum = 0 ; sumsq = 0;
DO i = 1 to 5
sum = sum + 1
sumsq = sumsq + i**2
END
SAY `sum=' sum `sumsq=' sumsq

The console displays the executed source lines, each pass through the DO/END loop, and the expression's final results. Removing the TRACE instruction, would display only the final result: sum = 15 sumsq = 55 .

Top Previous Next Chapter