By admin | August 10, 2009

SAS Certified Base Programmer 50 Questions (41)

A raw data file is listed below.

1---+----10---+----20---+---
01/05/1989    Frank     11
12/25/1987    June      13
01/05/1991    Sally      9

The following SAS program is submitted using the raw data file as input:

data work.family;
    infile 'file-specification';
    input @1 date_of_birth mmddyy10.
           @15 first_name $5.
           @25 age 3;
run;

proc print data=work.family noobs;
run;

Which one of the following is the result?

a. The program executes, but the age values are missing in the output.
b. The program executes, but the date values are missing in the output.
c. The program fails to execute because the age informat is coded incorrectly.
d. The program fails to execute because the date informat is coded incorrectly.

By admin | August 10, 2009

SAS Certified Base Programmer 50 Questions (40)

The following SAS program is submitted:

data work.test;
    set sasuser.class;
    array t{3} <insert text here> (5, 10, 15);
run;

Which one of the following completes the ARRAY statement and creates data elements that are not included in the SAS data set Work.Test?

a. _DROP_
b. _TEMP_
c. _TEMPORARY_
d. No extra text is needed.

By admin | August 10, 2009

SAS Certified Base Programmer 50 Questions (39)

An HTML file contains a SAS report. Which ODS statement option is used to specify
the name of the HTML file?

a. OUT=
b. FILE=
c. HTML=
d. HTMLFILE=

By admin | August 9, 2009

SAS Certified Base Programmer 50 Questions (38)

Assume the SAS data set Sasuser.Houses has four numeric variables.

The following SAS program is submitted:

proc means data=sasuser.houses mean;
    <insert statement(s) here>
run;

The following report is produced:

style N Obs Variable Mean
CONDO 4 bedrooms 2.7500000
baths 2.1250000
RANCH 4 bedrooms 2.2500002500000
baths 2.0000000
SPLIT 3 bedrooms 2.6666667
baths 1.8333333
TWOSTORY 4 bedrooms 3.0000000
baths 1.8750000

Which of the following statement(s) create(s) this report?

a. class style;

b. var bedrooms baths;

c. class style;
var bedrooms baths;

d. var style;
class bedrooms baths;

By admin | August 9, 2009

SAS Certified Base Programmer 50 Questions (37)

The following SAS program is submitted:

data work.accounting;
    length jobcode $ 12;
    set work.department;
run;

The Work.Department SAS data set contains a character variable named jobcode with a length of 5. Which of the following is the length of the variable jobcode in the output data set?

a. 5
b. 8
c. 12
d. The value cannot be determined because the program fails to execute due to syntax errors.