Item 41
Given the following macro program:
%macro MAKEPGM(NEWNAME, SETNAME, PRINT);
data &NEWNAME;
set &SETNAME;
run;
%if &PRINT=YES %then %do;
proc print data=&NEWNAME.(obs=10);
run ;
%end;
%mend;
Which option would provide feedback in the log about the parameter values passed into this macro when invoked?
A. MPRINT
B. MDEBUG
C. MLOGIC
D. MPARAM
答案是C。我怎么觉得是A呢?
Item 48
Given the following program and data:
data WORK.BDAYINFO;
infile datalines;
input Name $ Birthday : mmddyy10.;
datalines;
Alan 11/15/1950
Barb 08/23/1966
Carl 09/01/1963
;
run;
%let Want=23AUG1966;
proc print data=WORK.BDAYINFO;
[_insert_statement_]
run;
What is the WHERE statement that successfully completes the PROC PRINT and selects the observation for Barb?
A. where Birthday=&Want;
B. where Birthday=“&Want”;
C. where Birthday=“&Want”d;
D. where Birthday=‘&Want’d;
答案是C 日期加d不是应该单引吗? 应该是D才对? 为啥是C呢?
非常感谢!!!