SAS Base Programming for SAS 9 — Question 21

Given the SAS data set PEPM.STUDENTS:

PERM.STUDENTS NAME AGE -
--------- ------ Alfred 14

Alice13 -

Barbara13 -

Carol14 -
The following SAS program is submitted:
libname perm SAS data library;
data students;
set perm.students;
file file specification;
put name $15. @5 age 2.;
run;
What is written to the output raw data file?

Answer options

Correct answer: B

Explanation

The correct answer is B because the 'put' statement formats the names to fit within the specified width and appends the age directly after the name without a space. The other options are incorrect due to either incorrect formatting of names or ages, which do not adhere to the specified output structure.