open TextIO; fun put(0) = output(stdOut,"\n") | put(n) = (output(stdOut,"X"); put(n-1)); fun comb(n,m) = ( put(n); if m=0 orelse m=n then 1 else comb(n-1,m) + comb(n-1,m-1) ); comb(5,2);