d****r 发帖数: 2912 | 1 I think in Macro SAS, &y just literally subsitute the expression
of y into the expression, then calculate.
在 duo (多多逸善) 的大作中提到: 】
after you call v(3,8-1) the statement here is
x=3 - 8-1
not x=3-(8-1)
so you get -6 instead of -4.
Try this:
%macro v(y, z);
data a;
x=&y &z;
;
%mend;
%v(3-2*,2*2);
proc print ;
what is the result? I think you got it:)) |
|