SAS Question:
Download Questions PDF

How to add a number to a macro variable?

Answer:

Use %eval to do simple calculation for macro variables.
e.g.,
data _null_;
%let a = 1;
%let b = %eval(&a+1);
%put a=&a b=&b;
run;

Download SAS Interview Questions And Answers PDF

Previous QuestionNext Question
How to CREATE an external dataset with sas code?Code the tables statement for a single-level (most common) frequency?