1.
Given the SAS data set ONE:
ONE
Obs Dte
----- --------
1 09JAN2005
2 12JAN2005
The following SAS program is submitted:
data two;
set one;
day = ;
format dte date9.;
run;
The data set TWO is created:
TWO
Obs Dte Day
1 09JAN2005 1
12 JAN2005 4
Which expression successfully completed the program and created the variable DAY?
2.
Read the table:
Given the SAS data set SASUSER.HOUSES:
Obs style bedrooms baths price sqteet street
1 CONDO 2 1.5 80050 1200 MAIN
2 CONDO 3 2.5 79350 1300 ELM
3 CONDO 4 2.5 127150 1400 OAK
4 CONDO 2 2.0 110700 1100 FIFTH
5 TWOSTORY 4 3.0 107250 2100 SECOND
6 TWOSTORY 2 1.0 55650 1600 WEST
7 TWOSTORY 2 1.0 69250 1450 NORTH
6 TWOSTORY 4 2.5 102950 2000 SOUTH

The following SAS program is submitted:
proc report data = sasuser.houses nowd headline;
column style price;
where price It 100000;

define price / mean width = 9 format = dollar12.;
title;
run;
The following output is desired:
style price
------- ------
CONDO $79,700
TWOSTORY $62550
Which DEFINE statement completes the program and produces the desired output?
3.
The following SAS program is submitted:
proc contents data = sashelp.class varnum; quit;
What does the VARNUM option print?
4.
The following SAS program is submitted:
data test;
set chemists;
jobcode = 'Chem2'
then description = 'Senior Chemist';
else description = 'Unknown';
run;
The value for the variable JOBCODE is:
JOBCODE
-------------
chem2
What is the value of the variable DESCRIPTION?
5.
Given the AIRPLANES data set
AlRPLANES

TYPE MPG
-------- ------
F-18 105
C-130 25
Harrier 75
A-6 110
The following SAS program is submitted:
data gt100;
set airplanes(keep = type mpg load);
load = mpg * 150;
run;
The program fails to execute due to syntax errors.
What is the cause of the syntax error?
6.
Given the raw data file EMPLOYEE:
----I----1 0---I----20---I----30
Ruth 39 11
Jose 32 22
Sue 30 33
John 40 44
The following SAS program is submitted:

data test;
infile 'employee';
input employee_name $ 1-4;
if employee_name = 'Ruth' then input idnum 10-11;
else input age 7-8;
run;
What value does the variable IDNUM contain when the name of the employee is "Ruth"?
7.
The following SAS program is submitted:
data temp.x;
set sasuser.y;
run;
What must be submitted prior to this SAS program for the program to execute successfully?
8.
The data set RALESTATE has the variable LOCALFEE with a format or 9. and a variable
COUNTRYFEE with a format or 7.;
The following SAS program is submitted:
data history;
format local fee country fee percent6.;
set realestate;
local fee = local fee / 100;
country fee = country fee / 100;
run;
What are the formats of the variables LOCALFEE and COUNTRYFEE in the output dataset?
9.
The following SAS program is submitted:
proc freq data = class;
tables gender * age / ;
run;
The following report is created:
The FREQ Procedure
Table of gender by age

Row Column

Gender age Frequency Percent Percent Percent

F 11 1 10.00 20.00 50.00
12 2 20.00 40.00 40.00
13 2 20.00 40.00 66.67
Total 5 50.00 100.00
M 11 1 10.00 20.00 50.00
12 3 30.00 60.00 60,00
13 1 10.00 20.00 33.33
Total 5 50.00 100.00
Total 11 2 20.00 100.00
12 5 50.00 100.00
13 3 30.00 100.00
Total 10 100.00
Which option correctly completes the program and creates the report?
10.
The value 110700 is stored in a numeric variable named SALARY.
Which FORMAT statement displays the value as $110,700.00 in a report?