全部版块 我的主页
论坛 数据科学与人工智能 数据分析与数据科学 SAS专版
1671 3
2013-12-08
请教各位大侠,下面这题的答案为什么不是D?

The following SAS program is submitted:

data towns;

input City $ pop year;

cards;

ANDOVER 75000 1998

CARY    80000 1998

ANDOVER 14000 1977

CARY    71000 1986

;

%macro a(location);

data a;

set towns;

%if &location=UK %then %do;

where city='ANDOVER';

%end;

%if &location=NC %then %do;

where city='CARY';

%end;

if pop>70000;

run;

%mend;


%a(UK)


Which one of the following represents the resulting output in the SAS data set A?A. 1 observation with the value of CARY for the variable City

B. 2 observations with the value of CARY for the variable City

C. 1 observation with the value of ANDOVER for the variable City

D. 2 observations with the value of ANDOVER for the variable City
Correct answer: C

二维码

扫码加我 拉你入群

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

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

全部回复
2013-12-8 13:49:44
是不是少看了一句
if pop>70000;
二维码

扫码加我 拉你入群

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

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

2013-12-8 17:42:27
后面还有个if pop>70000
二维码

扫码加我 拉你入群

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

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

2013-12-8 21:03:44
Haha, you are right, many thanks!
二维码

扫码加我 拉你入群

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

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

相关推荐
栏目导航
热门文章
推荐文章

说点什么

分享

扫码加好友,拉您进群
各岗位、行业、专业交流群