[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: nargin
From: |
forkandwait |
Subject: |
Re: nargin |
Date: |
Wed, 14 Jul 2010 18:02:09 +0000 (UTC) |
User-agent: |
Loom/3.14 (http://gmane.org/) |
insipido <insipidbike <at> gmail.com> writes:
>
> > hello all,
> >
> > You all have to excuse me for doing such a dumb question but... can
> > any one explain to me in the easiest way what NARGIN function does,
It tells you how many parameters have been passed to a function. Number of
ARGuments In. There is a corresponding nargout, and some other related funcs.
Example:
function num_params = f()
num_params = nargin();
endfunction
> f(1,2,3,4)
ans = 4