That is not a recursive problem.
Assuming that you meant to set C to the value of B and not the other way around (since the other way around wouldn't produce your expected values).
data expect;
input A B expect;
cards;
11 6 6
2 27 27
7 12 12
8 . 96
3 . 288
4 . 1152
;
data want;
set expect ;
retain c;
if not missing(b) then c=b;
else c=a*c;
run;
proc print;
run;
Obs A B expect c
1 11 6 6 6
2 2 27 27 27
3 7 12 12 12
4 8 . 96 96
5 3 . 288 288
6 4 . 1152 1152