By admin | July 27, 2009

SAS Certified Base Programmer 50 Questions (5)

The following SAS program is submitted at the start of a new SAS session: libname sasdata ‘SAS-data-library’; data sasdata.sales; set sasdata.salesdata; profit=expenses-revenues; run; proc print data=sales; run; The SAS data set Sasdata.Salesdata has ten observations. Which one of the following explains why a report fails to generate? a. The DATA step fails execution. b. The […]

By admin | July 27, 2009

SAS Certified Base Programmer 50 Questions (4)

A raw data file is listed below. 1—+—-10—+—-20—+—-30—+—-40—+—-50 TWOSTORY 1040 2 1SANDERS ROAD $55,850 CONDO 2150 4 2.5JEANS AVENUE $127,150 The following program is submitted using this file as input: data work.houses; infile ‘file-specification’; <insert INPUT statement here> run; Which one of the following INPUT statements reads the raw data file correctly? a. input @1 […]

By admin | July 27, 2009

SAS Certified Base Programmer 50 Questions (3)

The following program is submitted: data numrecords; infile cards dlm=’,’; input agent1 $ agent2 $ agent3 $; cards; jones,,brownjones,spencer,brown ; run; What is the value for the variable named Agent2 in the second observation? a. brown b. spencer c. ”(missing character value) d. There is no value because only one observation is created

By admin | July 27, 2009

SAS Certified Base Programmer 50 Questions (2)

A raw data file is listed below. 1—+—-10—+—-20—+ Jose,47,210 Sue,,108 The following program is submitted using the raw data file above as input: data employeestats; <insert INFILE statement here> input name $ age weight; run; The following output is desired: name age weight Jose 47 210 Sue . 108 Which of the following INFILE statement […]

By admin | July 27, 2009

SAS Certified Base Programmer 50 Questions (1)

A raw data file is listed below. 1—+—-10—+—-20—+ son Frank 01/31/89 daughter June 12-25-87 brother Samuel 01/17/51 The following program is submitted using this file as input: data work.family; infile ‘file-specification’; <insert INPUT statement here> run; Which INPUT statement correctly reads the values for the variable Birthdate as SAS date values? a. input relation $ […]