Showing posts with label retain statement. Show all posts
Showing posts with label retain statement. Show all posts

Wednesday, April 17, 2013

Base SAS Certification Example Question 10.1

Assume ecsql1.employee_donations has 6 observations, and qtr1 has 6 values listed below:

100
200
300
.
150
50


What is the value of donation_tot after the 5th DATA step iteration?


data work.donations;
     set ecsql1.employee_donations (drop=qtr2-qtr4);
     retain donation_tot 1000;
     donation_tot + qtr1;
run;


a) 0
b) 750
c) 1750
d) Data step fails due to errors


*******************************************

Leave your answers as a comment below...good luck!

-SAS Cert