You may close function
, for
, while
, if
,
... blocks with endfunction
, endfor
, endwhile
,
... keywords in addition to using end
. As with Matlab, the
end
(or endfunction
) keyword that marks the end of a
function defined in a .m file is optional.