楼主: sunnibility
2717 3

[SAS EM] 三道SAS真题求解 [推广有奖]

  • 0关注
  • 0粉丝

小学生

14%

还不是VIP/贵宾

-

威望
0
论坛币
88 个
通用积分
0
学术水平
0 点
热心指数
0 点
信用等级
0 点
经验
86 点
帖子
3
精华
0
在线时间
6 小时
注册时间
2009-7-5
最后登录
2019-2-11

+2 论坛币
k人 参与回答

经管之家送您一份

应届毕业生专属福利!

求职就业群
赵安豆老师微信:zhaoandou666

经管之家联合CDA

送您一个全额奖学金名额~ !

感谢您参与论坛问题回答

经管之家送您两个论坛币!

+2 论坛币
大家好,

我是个新手玩家。刚做完SAS 70题,有四道题想大家请教一下。我自己很抓狂。想不明白。
======================================
Question 32: Consider the follwing data step:
data WORK.NEW;
set WORK.OLD;
    Count +1;
run;

The variable Count is created using a sum statement. Which statement regarding this variable is true?
    A. It is assigned a value 0 when the data step begins execution.
    B. It is assigned a value of missing when the data step begins execution.
    C. It is assigned a value 0 at compile time.
    D. It is assigned a value of missing at compile time.

答案是C 但是我不明白。如果这道题是C,那么53题呢?
======================================
Question 53: The following SAS program is submitted:
data WORK.TOTAL_SALARY;
    retain Total;
    set WORK.SALARY;
    by Department;
    if First.Department then Total =0;
    Total = sum(Total, Wagerate);
    if Last.Total;
Run;

What is the initial value of the variable Total?
A.   0
B.   Missing
C.   Thevalue of the first observation Wagerate
D.   Cannot be determined from the information given.

Answer B. 我觉得这两道题很像,但不知道为什么答案不一样。
======================================
Question 63: The following SAS program is submitted:

data WORK.OUTDS;
     do until(Prod GT 6);
        Prod + 1;
     end;
run;

What is the value of the variable Prod in the output data set?

A.   . (missing)
B.   6
C.   7
D.   Undetermined, infinite loop.

Answer C. 我运行程序也是7, 但do until 不是尾部判断吗?当Prod = 7 的时候,不是依然运行至尾部吗?答案不是8吗?我真的不懂了。请大家帮助。
======================================
Question 45 The following SAS program is submitted:
ods csvall file='c:\test.cvs';
proc print data = WORK.ONE;
    var Name Score Grade;
    by IDNumber;
run;
ods csvall close;

What is produced as output?

A.  A file named test.cvs that can only be opened in Excel.
B.  A text file named test.cvs that can be opened in Excel or inany text editor.
C.  A text file named test.cvs that can only be opened in a text editor.
D.  A file named test.cvs that can only be opened by SAS.

Answer C. 可是crackman网站上说这个答案是B。请大家帮我确认一下,应该是那个答案?

对不起, 一下子问了这么多问题。求高手解答。





二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

关键词:information observation Department Determined Informatio SAS Certification

沙发
sunnibility 发表于 2017-10-17 09:47:01 |只看作者 |坛友微信交流群
好冷清啊。顶一下。

使用道具

藤椅
l1i2n3i4n5g 在职认证  发表于 2017-10-17 13:56:04 |只看作者 |坛友微信交流群
Question 32:
data test;
   set sashelp.class;
   count+1;
run;
等价于
data test;
   set sashelp.class;
   retain count 0;
   count=count+1;
run;

Question 53:
retain total;
等价于
retain total .;

Question 63:
do until是先运行再判断条件,再运行,判断条件,运行,判断条件...直到条件不满足马上停止!
所以最后的prod是7

Question 45:
cvs(不是csv)默认是不能用excel打开的,但是硬要打开也行。

使用道具

板凳
sunnibility 发表于 2017-10-17 21:58:54 |只看作者 |坛友微信交流群
谢谢。受教了。

使用道具

您需要登录后才可以回帖 登录 | 我要注册

本版微信群
加好友,备注cda
拉您进交流群

京ICP备16021002-2号 京B2-20170662号 京公网安备 11010802022788号 论坛法律顾问:王进律师 知识产权保护声明   免责及隐私声明

GMT+8, 2024-4-19 13:41