This MATLAB function returns the number of output arguments specified in the call to the currently executing function.
www.mathworks.com