|
Examine variable values in a DO
loop. |
- Copy the program below and paste it into the Program Editor window (or issue the command
copy sashelp.oltutor..source ).
data work.earn;
Value=2000;
do year=1 to 20;
Interest=value*.075;
value+interest;
end;
run;
Include a PUT statement in the DO loop to write the value of the index variable
Year to the log during each iteration of the DO loop.
-
Submit the program.
-
Note the last value of
year written to the log.
Return here and select Next.
|
Copyright © 2002 SAS Institute Inc.,
Cary, NC, USA.
All rights reserved.
Terms of Use & Legal Information
| Privacy Statement