function B=f(A) /// \sleftarrow{\normalfont a typical {function} with one input and one output} B=string(sign(A)); B=strsubst(strsubst(B,'1','+'),'-+','-'); endfunction f(rand(2,5,'n') ) function y=fact(x) /// \sleftarrow{\normalfont a recursive {function} can be defined: \verb+fact+ calls \verb+fact+} if x <= 1 then y=x; else y=x*fact(x-1);end endfunction fact(4)