资源描述:
《sasbase70题(无答案解析版,适合练习)》由会员上传分享,免费在线阅读,更多相关内容在应用文档-天天文库。
1、SASBase认证考试—70题Q11.ThefollowingSASprogramissubmitted:dataWORK.TOTAL;setWORK.SALARY;byDepartmentGender;ifFirst.<_insert_code_>thenPayroll=0;Payroll+Wagerate;ifLast.<_insert_code_>;run;TheSASdatasetWORK.SALARYiscurrentlyorderedbyGenderwithinDepartment.Whichinsert
2、edcodewillaccumulatesubtotalsforeachGenderwithinDepartment?A.GenderB.DepartmentC.GenderDepartmentD.DepartmentGenderQ2GiventhefollowingrawdatarecordsinTEXTFILE.TXT:----
3、----10---
4、----20---
5、----30John,FEB,13,25,14,27,FinalJohn,MAR,26,17,29,11,23,CurrentTina,FEB,1
6、5,18,12,13,FinalTina,MAR,29,14,19,27,20,CurrentThefollowingoutputisdesired:ObsNameMonthStatusWeek1Week2Week3Week4Week51JohnFEBFinal$13$25$14$27.342JohnMARCurrent$26$17$29$11$233TinaFEBFinal$15$18$12$13.4TinaMARCurrent$29$14$19$27$20WhichSASprogramcorrectlyprodu
7、cesthedesiredoutput?A.dataWORK.NUMBERS;lengthName$4Month$3Status$7;infile'TEXTFILE.TXT'dsd;inputName$Month$;ifMonth='FEB'theninputWeek1Week2Week3Week4Status$;elseifMonth='MAR'theninputWeek1Week2Week3Week4Week5Status$;formatWeek1-Week5dollar6.;run;procprintdata=
8、WORK.NUMBERS;run;B.dataWORK.NUMBERS;lengthName$4Month$3Status$7;infile'TEXTFILE.TXT'dlm=','missover;inputName$Month$;ifMonth='FEB'theninputWeek1Week2Week3Week4Status$;elseifMonth='MAR'theninputWeek1Week2Week3Week4Week5Status$;formatWeek1-Week5dollar6.;run;procp
9、rintdata=WORK.NUMBERS;run;C.dataWORK.NUMBERS;lengthName$4Month$3Status$7;34infile'TEXTFILE.TXT'dlm=',';inputName$Month$@;ifMonth='FEB'theninputWeek1Week2Week3Week4Status$;elseifMonth='MAR'theninputWeek1Week2Week3Week4Week5Status$;formatWeek1-Week5dollar6.;run;p
10、rocprintdata=WORK.NUMBERS;run;D.dataWORK.NUMBERS;lengthName$4Month$3Status$7;infile'TEXTFILE.TXT'dsd@;inputName$Month$;ifMonth='FEB'theninputWeek1Week2Week3Week4Status$;elseifMonth='MAR'theninputWeek1Week2Week3Week4Week5Status$;formatWeek1-Week5dollar6.;run;pro
11、cprintdata=WORK.NUMBERS;run;Q3ThefollowingSASprogramissubmitted:dataWORK.DATE_INFO;Day="01";Yr=1960;X=mdy(Day,01,Yr);run;34WhatisthevalueofthevariableX?A.thenumericvalue0B.t