n*****5 发帖数: 61 | 1 A frequency report of the variable Jobcode in the Work.Actors data set is
listed
below.
Jobcode Frequency Percent Cumulative
Frequency Cumulative
Percent
Actor I 2 33.33 2 33.33
Actor II 2 33.33 4 66.67
Actor III 2 33.33 6 100.00
Frequency Missing = 1
The following SAS program is submitted:
data work.joblevels;
set work.actors;
if jobcode in ('Actor I', 'Actor II') then
joblevel='Beginner';
if jobcode='Actor III' then
joblevel='Advanced';
else joblevel='Unknown';
run;
Which of the following represents the possible values for the variable
joblevel in the
Work.Joblevels data set?
a. Advanced and Unknown only
b. Beginner and Advanced only
c. Beginner, Advanced, and Unknown
d. ' ' (missing character value)
Correct answer: a
why?不应该是b吗? | t*****w 发帖数: 254 | 2 else joblevel='Unknown';
will change the other into unknown;
if "if jobcode='Actor III' then joblevel='Advanced';" is changed into
"else if jobcode='Actor III' then joblevel='Advanced';",
the correct answer is b. |
|