SAS_Institute
A00-211 · Question #156
The following SAS program is submitted: data work.total; set work.salary(keep = department wagerate); by department; if first.department then payroll = 0; payroll + wagerate; if last.department run…
The correct answer is A. The WORK.TOTAL data set contains 5 observations. See the full explanation below for the reasoning.
Question
The following SAS program is submitted:
data work.total; set work.salary(keep = department wagerate); by department; if first.department then payroll = 0; payroll + wagerate; if last.department run; The SAS data set WORK.SALARY, currently ordered by DEPARTMENT, contains 100 observations for each of 5 departments. What is the result?
Options
- AThe WORK.TOTAL data set contains 5 observations.
- BThe WORKTDTAL data set contains 100 observations.
- CThe WORKTOTAL data set contains 500 observations.
- DThe program fails to execute due to errors.
How the community answered
(27 responses)- A81% (22)
- B4% (1)
- C4% (1)
- D11% (3)
Community Discussion
No community discussion yet for this question.