@FreelanceReinh wrote:
@Nidhi_vats wrote:
I also tried with these tree loops but is it possible that we can apply these three conditions in single and compact loop?
Hello @Nidhi_vats,
Is this "compact" enough?
data want;
set have;
length final $3;
_n_=3*(var2>10)*(var3~=15)+(var3>15)*((var2~=10)-2*(var2>10));
if _n_ then final=putc(cats(var1,'-',_n_),ifc(var1='b','$revers','$'),3);
run;
Slick.
Of course I am waiting for the OP to come back with another question involving var1 = d (or ??) and another operation like * ….
... View more