SAS-base-考试必备-70真题(附答案)(3)

2018-12-19 21:21

B.

Num Char --- ---- 1 23 1 77

C.

Num Char --- ---- 1 23 3 23 1 77

D. No output is generated.

Answer: D

-------------------------------------

20. The data set WORK.REALESTATE has the variable LocalFee with a format of 9. and a variable CountryFee with a format of 7.;

The following SAS program is submitted:

data WORK.FEE_STRUCTURE;

format LocalFee CountryFee percent7.2; set WORK.REALESTAT; LocalFee=LocalFee/100; CountryFee=CountryFee/100; run;

What are the formats of the variables LOCALFEE and COUNTRYFEE in the output dataset?

A. LocalFee has format of 9. and CountryFee has a format of 7.

B. LocalFee has format of 9. and CountryFee has a format of percent7.2 C. Both LocalFee and CountryFee have a format of percent7.2 D. The data step fails execution; there is no format for LocalFee.

Answer: C

-------------------------------------

21.Given the SAS data set WORK.PRODUCTS:

ProdId Price ProductType Sales Returns

------ ----- ----------- ----- -------

K12S 95.50 OUTDOOR 15 2 B132S 2.99 CLOTHING 300 10 R18KY2 51.99 EQUIPMENT 25 5 3KL8BY 6.39 OUTDOOR 125 15 DY65DW 5.60 OUTDOOR 45 5 DGTY23 34.55 EQUIPMENT 67 2

The following SAS program is submitted:

data WORK.OUTDOOR WORK.CLOTH WORK.EQUIP; set WORK.PRODUCTS; if Sales GT 30;

if ProductType EQ 'OUTDOOR' then output WORK.OUTDOOR; else if ProductType EQ 'CLOTHING' then output WORK.CLOTH; else if ProductType EQ 'EQUIPMENT' then output WORK.EQUIP; run;

How many observations does the WORK.OUTDOOR data set contain? A. 1 B. 2 C. 3 D. 6

Answer: B

-------------------------------------

22.Which step displays a listing of all the data sets in the WORK library? A. proc contents lib=WORK run; B. proc contents lib=WORK.all;run; C. proc contents data=WORK._all_; run; D. proc contents data=WORK _ALL_; run;

Answer: c

-------------------------------------

23.Which is a valid LIBNAME statement?

A. libname \

B. sasdata libname \ C. libname sasdata \ D. libname sasdata sas \

Answer: C

-------------------------------------

24.Given the following raw data records:

----|----10---|----20---|----30 Susan*12/29/1970*10 Michael**6

The following output is desired:

Obs employee bdate years 1 Susan 4015 10 2 Michael . 6

Which SAS program correctly reads in the raw data? A.

data employees;

infile 'file specification' dlm='*';

input employee $ bdate : mmddyy10. years; run;

B.

data employees;

infile 'file specification' dsd='*';

input employee $ bdate mmddyy10. years; run;

C.

data employees;

infile 'file specification' dlm dsd;

input employee $ bdate mmddyy10. years; run;

D.

data employees;

infile 'file specification' dlm='*' dsd;

input employee $ bdate : mmddyy10. years; run;

Answer: D

-------------------------------------

25.Given the following code:

proc print data=SASHELP.CLASS(firstobs=5 obs=15);

where Sex='M'; run;

How many observations will be displayed?

A. 11 B. 15

C. 10 or fewer D. 11 or fewer

Answer: D

-------------------------------------

26.Which step sorts the observations of a permanent SAS data set by two variables and stores the sorted observations in a temporary SAS data set?

A.

proc sort out=EMPLOYEES data=EMPSORT; by Lname and Fname; run;

B.

proc sort data=SASUSER.EMPLOYEES out=EMPSORT; by Lname Fname; run;

C.

proc sort out=SASUSER.EMPLOYEES data=WORK.EMPSORT; by Lname Fname; run;

D.

proc sort data=SASUSER.EMPLOYEES out=SASUSER.EMPSORT; by Lname and Fname; run;

Answer: B

-------------------------------------

27.Given the SAS data set WORK.TEMPS:

Day Month Temp --- ----- ----

1 May 75 15 May 70 15 June 80 3 June 76 2 July 85 14 July 89

The following program is submitted:

proc sort data=WORK.TEMPS; by descending Month Day; run;

proc print data=WORK.TEMPS; run;

Which output is correct?

A.

Obs Day Month Temp --- --- ----- ----

1 2 July 85 2 14 July 89 3 3 June 76 4 15 June 80 5 1 May 75 6 15 May 7

B.

Obs Day Month Temp --- --- ----- ----

1 1 May 75 2 2 July 85 3 3 June 76 4 14 July 89 5 15 May 70 6 15 June 80

C.

Obs Day Month Temp --- --- ----- ----

1 1 May 75 2 15 May 70


SAS-base-考试必备-70真题(附答案)(3).doc 将本文的Word文档下载到电脑 下载失败或者文档不完整,请联系客服人员解决!

下一篇:石油化工企业消防战训工作的研究

相关阅读
本类排行
× 注册会员免费下载(下载后可以自由复制和排版)

马上注册会员

注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信: QQ: